The currently available WS-API operations for asynchronous HMC jobs are:
Query Job Status
Delete Completed Job Status
Cancel Job
These operations need the "job-id" of the job.
There is no operation to list the currently present jobs.
What could be done in this situation is the following:
Whenever a command errors out or times out and has a job created that still runs, it should display the job-id of the job. Ideally in a way so it can be parsed using shell techniques.
Add new commands:
zhmc job status JOBID - performs "Query Job Status" and, and displays operation result
(for status "complete") or job status (for any other status)
zhmc job wait JOBID - polls using "Query Job Status" for the job to end, and displays operation result
(for status "complete") or cancellation status (for status "canceled")
zhmc job cancel JOBID - performs "Cancel Job", ignoring duplicate cancellations, then polls using
"Query Job Status" for the job to end, and displays operation result (for status "complete") or
cancellation status (for status "canceled")
zhmc job delete JOBID - performs "Delete Completed Job Status" and displays the deletion status.
The currently available WS-API operations for asynchronous HMC jobs are:
These operations need the "job-id" of the job.
There is no operation to list the currently present jobs.
What could be done in this situation is the following:
Whenever a command errors out or times out and has a job created that still runs, it should display the job-id of the job. Ideally in a way so it can be parsed using shell techniques.
Add new commands:
where JOBID is the job-id of the job.
This requires underlying support in the zhmcclient package (see https://github.com/zhmcclient/python-zhmcclient/issues/1299)