drmaa2_create_jsession
- drmaa2_create_jsession, Creates a persistent DRMAA2 job session.
#include "drmaa2.h"
drmaa2_jsession drmaa2_create_jsession(const char session_name, const char contact);
Creates a new and persistent job session on the Univa(R) Grid Engine(TM) master and opens it. For a successful creation a session with the name may not exist. The contact string must be NULL when using Univa(R) Grid Engine(TM).
Note: In Univa(R) Grid Engine(TM) DRMAA2 job sessions can be listed, created, and deleted also by qconf(3) calls.
On success a newly allocated drmaa2_jsession
object is returned. In case case of an failure NULL is returned and the error code and description is set for the calling thread.
drmaa2_jsession js = drmaa2_create_jsession("mysession", NULL);
if (js == NULL) {
/* an error happend */
drmaa2_string error = drmaa2_lasterror_text();
fprintf(stderr, "Error during creation of job session with the name %s: %s\n",
"mysession", error);
drmaa2_string_free(&error);
} else {
/* do something with the job session */
...
/* close jsession */
drmaa2_jsession_close(js);
/* free jsession */
drmaa2_jsession_free(&js);
}
drmaa2_close_jsession(3), drmaa2_open_jsession(3), drmaa2_destroy_jsession(3), drmaa2_jsession_free(3), drmaa2_jsession_get_jobs(3), drmaa_jsession_get_job_categories(3), drmaa2_jsession_run_job(3), drmaa2_jsession_run_bulk_jobs(3), drmaa2_jsession_wait_any_started(3), drmaa2_jsession_wait_any_terminated(3), drmaa2_jsession_get_contact(3), drmaa2_jsession_get_session_name(3), drmaa2_jsession_get_job_array(3)
Copyright Univa Corporation 2013