Class ExecutionInterceptorChain
- java.lang.Object
-
- software.amazon.awssdk.core.interceptor.ExecutionInterceptorChain
-
public class ExecutionInterceptorChain extends Object
A wrapper for a list ofExecutionInterceptor
s that ensures the interceptors are executed in the correct order as it is documented in theExecutionInterceptor
documentation. Interceptors are invoked in forward order up tobeforeTransmission(software.amazon.awssdk.core.interceptor.Context.BeforeTransmission, software.amazon.awssdk.core.interceptor.ExecutionAttributes)
and in reverse order after (and including)afterTransmission(software.amazon.awssdk.core.interceptor.Context.AfterTransmission, software.amazon.awssdk.core.interceptor.ExecutionAttributes)
. This ensures the last interceptors to modify the request are the first interceptors to see the response.
-
-
Constructor Summary
Constructors Constructor Description ExecutionInterceptorChain(List<ExecutionInterceptor> interceptors)
Create a chain that will execute the provided interceptors in the order they are provided.
-
Method Summary
-
-
-
Constructor Detail
-
ExecutionInterceptorChain
public ExecutionInterceptorChain(List<ExecutionInterceptor> interceptors)
Create a chain that will execute the provided interceptors in the order they are provided.
-
-
Method Detail
-
beforeExecution
public void beforeExecution(Context.BeforeExecution context, ExecutionAttributes executionAttributes)
-
modifyRequest
public InterceptorContext modifyRequest(InterceptorContext context, ExecutionAttributes executionAttributes)
-
beforeMarshalling
public void beforeMarshalling(Context.BeforeMarshalling context, ExecutionAttributes executionAttributes)
-
afterMarshalling
public void afterMarshalling(Context.AfterMarshalling context, ExecutionAttributes executionAttributes)
-
modifyHttpRequestAndHttpContent
public InterceptorContext modifyHttpRequestAndHttpContent(InterceptorContext context, ExecutionAttributes executionAttributes)
-
beforeTransmission
public void beforeTransmission(Context.BeforeTransmission context, ExecutionAttributes executionAttributes)
-
afterTransmission
public void afterTransmission(Context.AfterTransmission context, ExecutionAttributes executionAttributes)
-
modifyHttpResponse
public InterceptorContext modifyHttpResponse(InterceptorContext context, ExecutionAttributes executionAttributes)
-
modifyAsyncHttpResponse
public InterceptorContext modifyAsyncHttpResponse(InterceptorContext context, ExecutionAttributes executionAttributes)
-
beforeUnmarshalling
public void beforeUnmarshalling(Context.BeforeUnmarshalling context, ExecutionAttributes executionAttributes)
-
afterUnmarshalling
public void afterUnmarshalling(Context.AfterUnmarshalling context, ExecutionAttributes executionAttributes)
-
modifyResponse
public InterceptorContext modifyResponse(InterceptorContext context, ExecutionAttributes executionAttributes)
-
afterExecution
public void afterExecution(Context.AfterExecution context, ExecutionAttributes executionAttributes)
-
modifyException
public DefaultFailedExecutionContext modifyException(DefaultFailedExecutionContext context, ExecutionAttributes executionAttributes)
-
onExecutionFailure
public void onExecutionFailure(Context.FailedExecution context, ExecutionAttributes executionAttributes)
-
-