public class HttpChecksumInHeaderInterceptor extends Object implements ExecutionInterceptor
| Constructor and Description |
|---|
HttpChecksumInHeaderInterceptor() |
| Modifier and Type | Method and Description |
|---|---|
SdkHttpRequest |
modifyHttpRequest(Context.ModifyHttpRequest context,
ExecutionAttributes executionAttributes)
Calculates the checksum of the provided request (and base64 encodes it), and adds the header to the request.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitafterExecution, afterMarshalling, afterTransmission, afterUnmarshalling, beforeExecution, beforeMarshalling, beforeTransmission, beforeUnmarshalling, modifyAsyncHttpContent, modifyAsyncHttpResponseContent, modifyException, modifyHttpContent, modifyHttpResponse, modifyHttpResponseContent, modifyRequest, modifyResponse, onExecutionFailurepublic SdkHttpRequest modifyHttpRequest(Context.ModifyHttpRequest context, ExecutionAttributes executionAttributes)
Note: This assumes that the content stream provider can create multiple new streams. If it only supports one (e.g. with an input stream that doesn't support mark/reset), we could consider buffering the content in memory here and updating the request body to use that buffered content. We obviously don't want to do that for giant streams, so we haven't opted to do that yet.
modifyHttpRequest in interface ExecutionInterceptorcontext - The current state of the execution, including the SDK and current HTTP request.executionAttributes - A mutable set of attributes scoped to one specific request/response cycle that can be used to
give data to future lifecycle methods.Copyright © 2023. All rights reserved.