A method for forcing a running job to shut down.
Parameters:
Raises:
Source code in docs_src/capo_sagemaker/_services/async_sage_maker.py
| async def stop_auto_ml_job(
self,
*,
config_overrides: Optional[AsyncSageMakerClientConfig] = None,
auto_ml_job_name: Optional[
"capo_sagemaker.types.auto_ml_job_name.AutoMLJobName"
] = None,
) -> None:
"""<p>A method for forcing a running job to shut down.</p>
Args:
auto_ml_job_name: <p>The name of the object you are requesting.</p>
Raises:
capo_sagemaker.errors.resource_not_found.ResourceNotFound: <p>Resource being access is not found.</p>
capo_sagemaker.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_sagemaker.types.stop_auto_ml_job_request.StopAutoMLJobRequest]",
) -> AsyncOperationResponse[None]:
import capo_sagemaker._operations.sage_maker.stop_auto_ml_job
(
output,
http_response,
) = await capo_sagemaker._operations.sage_maker.stop_auto_ml_job.async_stop_auto_ml_job(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("StopAutoMLJob")
)
input_: capo_sagemaker.types.stop_auto_ml_job_request.StopAutoMLJobRequest = {}
if auto_ml_job_name is not None:
input_["auto_ml_job_name"] = auto_ml_job_name
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|