Interface Context.FailedExecution
-
- All Known Implementing Classes:
DefaultFailedExecutionContext
- Enclosing class:
- Context
@ThreadSafe public static interface Context.FailedExecution
All information that is known about a particular execution that has failed. This is given toExecutionInterceptor.onExecutionFailure(software.amazon.awssdk.core.interceptor.Context.FailedExecution, software.amazon.awssdk.core.interceptor.ExecutionAttributes)if an entire execution fails for any reason. This includes all information that is known about the request, like therequest()and theexception()that caused the failure.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Throwableexception()The exception associated with the failed execution.Optional<SdkHttpRequest>httpRequest()The latest version of theSdkHttpRequestavailable when the execution failed.Optional<SdkHttpResponse>httpResponse()The latest version of theSdkHttpResponseavailable when the execution failed.SdkRequestrequest()The latest version of theSdkRequestavailable when the execution failed.Optional<SdkResponse>response()The latest version of theSdkResponseavailable when the execution failed.
-
-
-
Method Detail
-
exception
Throwable exception()
The exception associated with the failed execution. This is the reason the execution has failed, and is the exception that will be returned or thrown from the client method call. This will never return null.
-
request
SdkRequest request()
The latest version of theSdkRequestavailable when the execution failed. This will never return null.
-
httpRequest
Optional<SdkHttpRequest> httpRequest()
The latest version of theSdkHttpRequestavailable when the execution failed. This may be aSdkHttpFullRequest; if so, it can be accessed by casting the returnedSdkHttpRequest. If the execution failed before or during request marshalling, this will returnOptional.empty().
-
httpResponse
Optional<SdkHttpResponse> httpResponse()
The latest version of theSdkHttpResponseavailable when the execution failed. This may be aSdkHttpFullResponse; if so, it can be accessed by casting the returnedSdkHttpResponse. If the execution failed before or during transmission, this will returnOptional.empty().
-
response
Optional<SdkResponse> response()
The latest version of theSdkResponseavailable when the execution failed. If the execution failed before or during response unmarshalling, this will returnOptional.empty().
-
-