Stops one or more job runs for a specified job definition.
Parameters:
-
job_name
(NameString)
–
The name of the job definition for which to stop job runs.
-
job_run_ids
(BatchStopJobRunJobRunIdList)
–
A list of the JobRunIds that should be stopped for that job definition.
Raises:
Source code in docs_src/capo_glue/_services/glue.py
| def batch_stop_job_run(
self,
job_name: "capo_glue.types.name_string.NameString",
job_run_ids: "capo_glue.types.batch_stop_job_run_job_run_id_list.BatchStopJobRunJobRunIdList",
*,
config_overrides: Optional[GlueClientConfig] = None,
) -> "capo_glue.types.batch_stop_job_run_response.BatchStopJobRunResponse":
"""<p>Stops one or more job runs for a specified job definition.</p>
Args:
job_name: <p>The name of the job definition for which to stop job runs.</p>
job_run_ids: <p>A list of the <code>JobRunIds</code> that should be stopped for that job definition.</p>
Raises:
capo_glue.errors.internal_service_exception.InternalServiceException: <p>An internal service error occurred.</p>
capo_glue.errors.invalid_input_exception.InvalidInputException: <p>The input provided was not valid.</p>
capo_glue.errors.operation_timeout_exception.OperationTimeoutException: <p>The operation timed out.</p>
capo_glue.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_glue.types.batch_stop_job_run_request.BatchStopJobRunRequest]",
) -> OperationResponse[
"capo_glue.types.batch_stop_job_run_response.BatchStopJobRunResponse"
]:
import capo_glue._operations.aws_glue.batch_stop_job_run
output, http_response = (
capo_glue._operations.aws_glue.batch_stop_job_run.batch_stop_job_run(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("BatchStopJobRun")
)
input_: capo_glue.types.batch_stop_job_run_request.BatchStopJobRunRequest = {
"job_name": job_name,
"job_run_ids": job_run_ids,
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|