The job provides the manageability interface to a job instance submitted to a resource manager. More...
#include <job.hpp>
Public Member Functions | |
job () | |
Creates the object. | |
job (saga::object const &o) | |
Creates the object. | |
~job () | |
Destroys the object. | |
job & | operator= (saga::object const &o) |
Brief description starts here. | |
std::string | get_job_id () |
Brief description starts here. | |
void | run () |
Start the job. | |
bool | wait (double timeout=-1.0) |
Wait for the job to complete. | |
void | cancel (double timeout=0.0) |
Cancel the job. | |
saga::job::state | get_state () |
Get the state of the job. | |
saga::job::description | get_description () |
Retrieve the description which was used to submit this job instance. | |
saga::job::ostream | get_stdin () |
Retrieve input stream for a job. | |
saga::job::istream | get_stdout () |
Retrieve output stream of job. | |
saga::job::istream | get_stderr () |
Retrieve error stream of job. | |
void | suspend () |
Ask the resource manager to suspend this job. | |
void | resume () |
Ask the resource manager to resume this job. | |
void | checkpoint () |
Ask the resource manager to checkpoint this job. | |
void | migrate (description job_desc) |
Ask the resource manager to migrate this job. | |
void() | signal (int signal) |
Ask the resource manager to deliver an arbitrary signal to this job. |
The job provides the manageability interface to a job instance submitted to a resource manager.
There are two general types of methods: those for retrieving job state and information, and those for manipulating the job. The methods intended to manipulate jobs cannot make any guarantees about how the resource manager will affect an action to be taken. The API implementation is designed to be agnostic of the backend implementation, such that any backend could be implemented to perform an action. For example, the checkpoint routine might cause an application level checkpoint, or might use the services of GridCPR.
Definition at line 224 of file packages/job/job.hpp.
saga::job::job::job | ( | saga::object const & | o | ) | [explicit] |
Creates the object.
Definition at line 205 of file job.cpp.
References saga::BadParameter, saga::object::get_type(), and saga::object::Job.
job & saga::job::job::operator= | ( | saga::object const & | o | ) |
std::string saga::job::job::get_job_id | ( | ) | [inline] |
Brief description starts here.
Definition at line 298 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::run | ( | ) | [inline] |
Start the job.
Definition at line 309 of file packages/job/job.hpp.
References saga::task::get_result().
bool saga::job::job::wait | ( | double | timeout = -1.0 |
) | [inline] |
Wait for the job to complete.
Definition at line 320 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::cancel | ( | double | timeout = 0.0 |
) | [inline] |
Cancel the job.
Definition at line 331 of file packages/job/job.hpp.
References saga::task::get_result().
saga::job::state saga::job::job::get_state | ( | ) | [inline] |
Get the state of the job.
Definition at line 343 of file packages/job/job.hpp.
References saga::task::get_result().
saga::job::description saga::job::job::get_description | ( | ) | [inline] |
Retrieve the description which was used to submit this job instance.
Definition at line 356 of file packages/job/job.hpp.
References saga::task::get_result().
saga::job::ostream saga::job::job::get_stdin | ( | ) | [inline] |
Retrieve input stream for a job.
Definition at line 368 of file packages/job/job.hpp.
References saga::task::get_result().
saga::job::istream saga::job::job::get_stdout | ( | ) | [inline] |
Retrieve output stream of job.
Definition at line 381 of file packages/job/job.hpp.
References saga::task::get_result().
saga::job::istream saga::job::job::get_stderr | ( | ) | [inline] |
Retrieve error stream of job.
Definition at line 394 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::suspend | ( | ) | [inline] |
Ask the resource manager to suspend this job.
Definition at line 406 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::resume | ( | ) | [inline] |
Ask the resource manager to resume this job.
Definition at line 418 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::checkpoint | ( | void | ) | [inline] |
Ask the resource manager to checkpoint this job.
Definition at line 430 of file packages/job/job.hpp.
References saga::task::get_result().
void saga::job::job::migrate | ( | description | job_desc | ) | [inline] |
Ask the resource manager to migrate this job.
job_desc | New job parameters to apply when the job is migrated |
Definition at line 443 of file packages/job/job.hpp.
References saga::task::get_result().
void() saga::job::job::signal | ( | int | signal | ) | [inline] |
Ask the resource manager to deliver an arbitrary signal to this job.
signum | Signal number to be delivered |
Definition at line 457 of file packages/job/job.hpp.
References saga::task::get_result().