Describes a job execution.
Requires permission to access the DescribeJobExecution action.
Parameters:
-
job_id
(JobId)
–
The unique identifier you assigned to this job when it was created.
-
thing_name
(ThingName)
–
The name of the thing on which the job execution is running.
-
execution_number
(Optional[ExecutionNumber], default:
None
)
–
A string (consisting of the digits "0" through "9" which is used to specify a particular job execution on a particular device.
Raises:
Source code in docs_src/capo_iot/_services/io_t.py
| def describe_job_execution(
self,
job_id: "capo_iot.types.job_id.JobId",
thing_name: "capo_iot.types.thing_name.ThingName",
*,
config_overrides: Optional[IoTClientConfig] = None,
execution_number: Optional[
"capo_iot.types.execution_number.ExecutionNumber"
] = None,
) -> "capo_iot.types.describe_job_execution_response.DescribeJobExecutionResponse":
"""<p>Describes a job execution.</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">DescribeJobExecution</a> action.</p>
Args:
job_id: <p>The unique identifier you assigned to this job when it was created.</p>
thing_name: <p>The name of the thing on which the job execution is running.</p>
execution_number: <p>A string (consisting of the digits "0" through "9" which is used to specify a particular job execution on a particular device.</p>
Raises:
capo_iot.errors.invalid_request_exception.InvalidRequestException: <p>The request is not valid.</p>
capo_iot.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource does not exist.</p>
capo_iot.errors.service_unavailable_exception.ServiceUnavailableException: <p>The service is temporarily unavailable.</p>
capo_iot.errors.throttling_exception.ThrottlingException: <p>The rate exceeds the limit.</p>
capo_iot.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_iot.types.describe_job_execution_request.DescribeJobExecutionRequest]",
) -> OperationResponse[
"capo_iot.types.describe_job_execution_response.DescribeJobExecutionResponse"
]:
import capo_iot._operations.aws_iot_service.describe_job_execution
output, http_response = (
capo_iot._operations.aws_iot_service.describe_job_execution.describe_job_execution(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DescribeJobExecution")
)
input_: capo_iot.types.describe_job_execution_request.DescribeJobExecutionRequest = {
"job_id": job_id,
"thing_name": thing_name,
}
if execution_number is not None:
input_["execution_number"] = execution_number
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|