Gets the list of all jobs for a thing that are not in a terminal status.
Requires permission to access the GetPendingJobExecutions action.
Parameters:
-
thing_name
(ThingName)
–
The name of the thing that is executing the job.
Raises:
Source code in docs_src/capo_iot_jobs_data_plane/_services/async_io_t_jobs_data_plane.py
| async def get_pending_job_executions(
self,
thing_name: "capo_iot_jobs_data_plane.types.thing_name.ThingName",
*,
config_overrides: Optional[AsyncIoTJobsDataPlaneClientConfig] = None,
) -> "capo_iot_jobs_data_plane.types.get_pending_job_executions_response.GetPendingJobExecutionsResponse":
"""<p>Gets the list of all jobs for a thing that are not in a terminal status.</p> <p>Requires permission to access the <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsiot.html#awsiot-actions-as-permissions">GetPendingJobExecutions</a> action.</p>
Args:
thing_name: <p>The name of the thing that is executing the job.</p>
Raises:
capo_iot_jobs_data_plane.errors.certificate_validation_exception.CertificateValidationException: <p>The certificate is invalid.</p>
capo_iot_jobs_data_plane.errors.invalid_request_exception.InvalidRequestException: <p>The contents of the request were invalid.</p>
capo_iot_jobs_data_plane.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource does not exist.</p>
capo_iot_jobs_data_plane.errors.service_unavailable_exception.ServiceUnavailableException: <p>The service is temporarily unavailable.</p>
capo_iot_jobs_data_plane.errors.throttling_exception.ThrottlingException: <p>The rate exceeds the limit.</p>
capo_iot_jobs_data_plane.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_iot_jobs_data_plane.types.get_pending_job_executions_request.GetPendingJobExecutionsRequest]",
) -> AsyncOperationResponse[
"capo_iot_jobs_data_plane.types.get_pending_job_executions_response.GetPendingJobExecutionsResponse"
]:
import capo_iot_jobs_data_plane._operations.iot_laser_thing_job_manager_external_service.get_pending_job_executions
(
output,
http_response,
) = await capo_iot_jobs_data_plane._operations.iot_laser_thing_job_manager_external_service.get_pending_job_executions.async_get_pending_job_executions(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("GetPendingJobExecutions")
)
input_: capo_iot_jobs_data_plane.types.get_pending_job_executions_request.GetPendingJobExecutionsRequest = {
"thing_name": thing_name
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|