Package examples.zosjobs
Class MonitorJobs
- java.lang.Object
-
- examples.ZosConnection
-
- examples.zosjobs.MonitorJobs
-
public class MonitorJobs extends ZosConnection
Class example to showcase MonitorJobs functionality.- Version:
- 1.0
- Author:
- Frank Giordano
-
-
Field Summary
-
Fields inherited from class examples.ZosConnection
hostName, password, userName, zosmfPort
-
-
Constructor Summary
Constructors Constructor Description MonitorJobs()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidmain(String[] args)Main method defines z/OSMF host and user connection needed to showcase MonitorJobs functionality.static voidmonitorIsJobRunning()static voidmonitorJobsForOutputStatusByJobNameAndId()Example on how to call MonitorJobs waitForJobOutputStatus method.static voidmonitorJobsForOutputStatusByJobObject()Example on how to call MonitorJobs waitForJobOutputStatus method.static voidmonitorJobsForStatusByJobNameAndId(JobStatus.Type statusType)Example on how to call MonitorJobs waitForJobStatus method.static voidmonitorJobsForStatusByJobObject(JobStatus.Type statusType)Example on how to call MonitorJobs waitForJobStatus method.static voidmonitorWaitForJobMessage(String message)Example on how to call MonitorJobs tstMonitorWaitForJobMessage method.
-
-
-
Method Detail
-
main
public static void main(String[] args) throws Exception
Main method defines z/OSMF host and user connection needed to showcase MonitorJobs functionality. Calls MonitorJobs example methods.- Parameters:
args- for main not used- Throws:
Exception- error in processing request
-
monitorJobsForOutputStatusByJobObject
public static void monitorJobsForOutputStatusByJobObject() throws ExceptionExample on how to call MonitorJobs waitForJobOutputStatus method. waitForJobOutputStatus accepts a job object which will monitor the job status until it reaches OUTPUT status or times out if not reached.- Throws:
Exception- error in processing request
-
monitorJobsForOutputStatusByJobNameAndId
public static void monitorJobsForOutputStatusByJobNameAndId() throws ExceptionExample on how to call MonitorJobs waitForJobOutputStatus method. waitForJobOutputStatus accepts a jobName and jobId values which will monitor the job status until it reaches OUTPUT status or times out if not reached.- Throws:
Exception- error in processing request
-
monitorJobsForStatusByJobObject
public static void monitorJobsForStatusByJobObject(JobStatus.Type statusType) throws Exception
Example on how to call MonitorJobs waitForJobStatus method. waitForJobStatus accepts a job object and status value which will monitor the job status until it reaches the given status value or times out if not reached.- Parameters:
statusType- given status type to use for monitoring- Throws:
Exception- error in processing request
-
monitorJobsForStatusByJobNameAndId
public static void monitorJobsForStatusByJobNameAndId(JobStatus.Type statusType) throws Exception
Example on how to call MonitorJobs waitForJobStatus method. waitForJobStatus accepts a jobName and jobId values and status value which will monitor the job status until it reaches the given status value or times out if not reached.- Parameters:
statusType- given status type to use for monitoring- Throws:
Exception- error in processing request
-
monitorWaitForJobMessage
public static void monitorWaitForJobMessage(String message) throws Exception
Example on how to call MonitorJobs tstMonitorWaitForJobMessage method. tstMonitorWaitForJobMessage accepts a message value which will monitor the job output until the message is seen or times out if not seen.- Parameters:
message- given message text to monitor job output- Throws:
Exception- error in processing request
-
-