|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Job
Jobs are created by a JobService
, using a JobDescription
.
The Job
interface extends the
Task
interface, but jobs don't have an
associated Saga object or a result object, so the generic instantiation
parameters are Void
.
Field Summary | |
---|---|
static String |
CREATED
Attribute name, time stamp of the job creation in the resource manager. |
static String |
EXECUTIONHOSTS
Attribute name, list of host names or IP addresses allocated to run this job. |
static String |
EXITCODE
Attribute name, process exit code. |
static String |
FINISHED
Attribute name, time stamp indicating when the job finished. |
static String |
JOB_CPUTIME
Metric name, number of CPU seconds consumed by the job. |
static String |
JOB_MEMORYUSE
Metric name, current aggregate memory usage of the job. |
static String |
JOB_PERFORMANCE
Metric name, current performance. |
static String |
JOB_SIGNAL
Metric name, fires as a job receives a signal. |
static String |
JOB_STATE
Metric name, fires on state changes of the job. |
static String |
JOB_STATEDETAIL
Metric name, fires as a job changes its state detail. |
static String |
JOB_VMEMORYUSE
Metric name, current aggregate virtual memory usage of the job. |
static String |
JOBID
Attribute name, SAGA representation of the job identifier. |
static String |
SERVICEURL
Attribute name, URL representation of the JobService that created the job. |
static String |
STARTED
Attribute name, time stamp indicating when the job started running. |
static String |
TERMSIG
Attribute name, signal number which caused the job to exit. |
static String |
WORKINGDIRECTORY
Attribute name, working directory on the execution host. |
Fields inherited from interface org.ogf.saga.task.Task |
---|
TASK_STATE |
Fields inherited from interface org.ogf.saga.SagaObject |
---|
NO_WAIT, WAIT_FOREVER |
Fields inherited from interface org.ogf.saga.attributes.Attributes |
---|
BOOL, ENUM, FALSE, FLOAT, INT, STRING, TIME, TRIGGER, TRUE |
Method Summary | |
---|---|
void |
checkpoint()
Asks the resource manager to initiate a checkpoint operation on a running job. |
Task<Job,Void> |
checkpoint(TaskMode mode)
Creates a task that asks the resource manager to initiate a checkpoint operation on a running job. |
JobDescription |
getJobDescription()
Retrieves the job description that was used to submit this job instance. |
Task<Job,JobDescription> |
getJobDescription(TaskMode mode)
Creates a task that retrieves the job description that was used to submit this job instance. |
InputStream |
getStderr()
Returns the error stream of this job (which can be read). |
Task<Job,InputStream> |
getStderr(TaskMode mode)
Creates a task that obtains the error stream of this job (which can be read). |
OutputStream |
getStdin()
Returns the input stream of this job (to which can be written). |
Task<Job,OutputStream> |
getStdin(TaskMode mode)
Creates a task that obtains the input stream of this job (to which can be written). |
InputStream |
getStdout()
Returns the output stream of this job (which can be read). |
Task<Job,InputStream> |
getStdout(TaskMode mode)
Creates a task that obtains the output stream of this job (which can be read). |
void |
migrate(JobDescription jd)
Asks the resource manager to migrate a job. |
Task<Job,Void> |
migrate(TaskMode mode,
JobDescription jd)
Creates a task that asks the resource manager to migrate a job. |
void |
resume()
Asks the resource manager to perform a resume operation on a suspended job. |
Task<Job,Void> |
resume(TaskMode mode)
Creates a task that asks the resource manager to perform a resume operation on a suspended job. |
void |
signal(int signum)
Asks the resource manager to deliver an arbitrary signal to a dispatched job. |
Task<Job,Void> |
signal(TaskMode mode,
int signum)
Creates a task that asks the resource manager to deliver an arbitrary signal to a dispatched job. |
void |
suspend()
Asks the resource manager to perform a suspend operation on a running job. |
Task<Job,Void> |
suspend(TaskMode mode)
Creates a task that asks the resource manager to perform a suspend operation on a running job. |
Methods inherited from interface org.ogf.saga.task.Task |
---|
cancel, cancel, getObject, getResult, getState, rethrow, run, waitFor, waitFor |
Methods inherited from interface org.ogf.saga.SagaObject |
---|
clone, getId, getSession |
Methods inherited from interface org.ogf.saga.monitoring.Monitorable |
---|
addCallback, getMetric, listMetrics, removeCallback |
Methods inherited from interface java.util.concurrent.Future |
---|
cancel, get, get, isCancelled, isDone |
Methods inherited from interface org.ogf.saga.attributes.AsyncAttributes |
---|
existsAttribute, findAttributes, getAttribute, getVectorAttribute, isReadOnlyAttribute, isRemovableAttribute, isVectorAttribute, isWritableAttribute, listAttributes, removeAttribute, setAttribute, setVectorAttribute |
Methods inherited from interface org.ogf.saga.attributes.Attributes |
---|
existsAttribute, findAttributes, getAttribute, getVectorAttribute, isReadOnlyAttribute, isRemovableAttribute, isVectorAttribute, isWritableAttribute, listAttributes, removeAttribute, setAttribute, setVectorAttribute |
Methods inherited from interface org.ogf.saga.permissions.Permissions |
---|
getGroup, getGroup, getOwner, getOwner, permissionsAllow, permissionsAllow, permissionsCheck, permissionsCheck, permissionsDeny, permissionsDeny |
Field Detail |
---|
static final String JOBID
static final String SERVICEURL
static final String EXECUTIONHOSTS
static final String CREATED
static final String STARTED
static final String FINISHED
static final String WORKINGDIRECTORY
static final String EXITCODE
static final String TERMSIG
static final String JOB_STATE
static final String JOB_STATEDETAIL
static final String JOB_SIGNAL
static final String JOB_CPUTIME
static final String JOB_MEMORYUSE
static final String JOB_VMEMORYUSE
static final String JOB_PERFORMANCE
Method Detail |
---|
JobDescription getJobDescription() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, DoesNotExistException, TimeoutException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
DoesNotExistException
- is thrown in cases where the job description is not available,
for instance when the job was not submitted through SAGA and the
job was obtained using the JobService.getJob(String)
call.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.OutputStream getStdin() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, BadParameterException, DoesNotExistException, TimeoutException, IncorrectStateException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
DoesNotExistException
- is thrown when the stream is not available for some reason.
IncorrectStateException
- is thrown when the job is not interactive.
BadParameterException
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.InputStream getStdout() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, BadParameterException, DoesNotExistException, TimeoutException, IncorrectStateException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
DoesNotExistException
- is thrown when the stream is not available for some reason.
IncorrectStateException
- is thrown when the job is not interactive.
BadParameterException
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.InputStream getStderr() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, BadParameterException, DoesNotExistException, TimeoutException, IncorrectStateException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
DoesNotExistException
- is thrown when the stream is not available for some reason.
IncorrectStateException
- is thrown when the job is not interactive.
BadParameterException
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.void suspend() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, IncorrectStateException, TimeoutException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
IncorrectStateException
- is thrown when the job is not in RUNNING state.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.void resume() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, IncorrectStateException, TimeoutException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
IncorrectStateException
- is thrown when the job is not in SUSPENDED state.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.void checkpoint() throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, IncorrectStateException, TimeoutException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
IncorrectStateException
- is thrown when the job is not in RUNNING state.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.void migrate(JobDescription jd) throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, BadParameterException, IncorrectStateException, TimeoutException, NoSuccessException
jd
- new job parameters to apply when the job is migrated.
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
IncorrectStateException
- is thrown when the job is not in RUNNING or SUSPENDED state.
BadParameterException
- is thrown if there is something wrong with the specified
job description.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.void signal(int signum) throws NotImplementedException, AuthenticationFailedException, AuthorizationFailedException, PermissionDeniedException, BadParameterException, IncorrectStateException, TimeoutException, NoSuccessException
NotImplementedException
- is thrown if the implementation does not provide an
implementation of this method.
PermissionDeniedException
- is thrown when the method failed because the identity used did
not have sufficient permissions to perform the operation
successfully.
AuthorizationFailedException
- is thrown when none of the available contexts of the
used session could be used for successful authorization.
This error indicates that the resource could not be accessed
at all, and not that an operation was not available due to
restricted permissions.
AuthenticationFailedException
- is thrown when operation failed because none of the available
session contexts could successfully be used for authentication.
TimeoutException
- is thrown when a remote operation did not complete successfully
because the network communication or the remote service timed
out.
IncorrectStateException
- is thrown when the job is not in RUNNING or SUSPENDED state.
BadParameterException
- is thrown if the specified signal is not supported by the backend.
NoSuccessException
- is thrown when the operation was not successfully performed,
and none of the other exceptions apply.Task<Job,JobDescription> getJobDescription(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,OutputStream> getStdin(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,InputStream> getStdout(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,InputStream> getStderr(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,Void> suspend(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,Void> resume(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,Void> checkpoint(TaskMode mode) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,Void> migrate(TaskMode mode, JobDescription jd) throws NotImplementedException
jd
- new job parameters to apply when the job is migrated.mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.Task<Job,Void> signal(TaskMode mode, int signum) throws NotImplementedException
mode
- the task mode.
NotImplementedException
- is thrown when the task version of this method is not
implemented.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |