Class RequestOverrideConfiguration
- java.lang.Object
-
- software.amazon.awssdk.core.RequestOverrideConfiguration
-
- Direct Known Subclasses:
SdkRequestOverrideConfiguration
@Immutable public abstract class RequestOverrideConfiguration extends Object
Base per-request override configuration for all SDK requests.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
RequestOverrideConfiguration.Builder<B extends RequestOverrideConfiguration.Builder>
protected static class
RequestOverrideConfiguration.BuilderImpl<B extends RequestOverrideConfiguration.Builder>
-
Constructor Summary
Constructors Modifier Constructor Description protected
RequestOverrideConfiguration(RequestOverrideConfiguration.Builder<?> builder)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Optional<Duration>
apiCallAttemptTimeout()
The amount of time to wait for the http request to complete before giving up and timing out.Optional<Duration>
apiCallTimeout()
The amount of time to allow the client to complete the execution of an API call.List<ApiName>
apiNames()
The optional names of the higher level libraries that constructed the request.Optional<CompressionConfiguration>
compressionConfiguration()
Returns the compression configuration object, if present, which includes options to enable/disable compression and set the minimum compression threshold.Optional<EndpointProvider>
endpointProvider()
Returns the endpoint provider for resolving the endpoint for this request.boolean
equals(Object o)
ExecutionAttributes
executionAttributes()
Returns the additional execution attributes to be added to this request.int
hashCode()
Map<String,List<String>>
headers()
Optional additional headers to be added to the HTTP request.List<MetricPublisher>
metricPublishers()
Return the metric publishers for publishing the metrics collected for this request.List<SdkPlugin>
plugins()
Return the plugins that will be used to update the configuration used by the request.Map<String,List<String>>
rawQueryParameters()
Optional additional query parameters to be added to the HTTP request.Optional<Signer>
signer()
abstract RequestOverrideConfiguration.Builder<? extends RequestOverrideConfiguration.Builder>
toBuilder()
Create aRequestOverrideConfiguration.Builder
initialized with the properties of thisSdkRequestOverrideConfiguration
.
-
-
-
Constructor Detail
-
RequestOverrideConfiguration
protected RequestOverrideConfiguration(RequestOverrideConfiguration.Builder<?> builder)
-
-
Method Detail
-
headers
public Map<String,List<String>> headers()
Optional additional headers to be added to the HTTP request.- Returns:
- The optional additional headers.
-
rawQueryParameters
public Map<String,List<String>> rawQueryParameters()
Optional additional query parameters to be added to the HTTP request.- Returns:
- The optional additional query parameters.
-
apiNames
public List<ApiName> apiNames()
The optional names of the higher level libraries that constructed the request.- Returns:
- The names of the libraries.
-
apiCallTimeout
public Optional<Duration> apiCallTimeout()
The amount of time to allow the client to complete the execution of an API call. This timeout covers the entire client execution except for marshalling. This includes request handler execution, all HTTP requests including retries, unmarshalling, etc. This value should always be positive, if present.The api call timeout feature doesn't have strict guarantees on how quickly a request is aborted when the timeout is breached. The typical case aborts the request within a few milliseconds but there may occasionally be requests that don't get aborted until several seconds after the timer has been breached. Because of this, the client execution timeout feature should not be used when absolute precision is needed.
This may be used together with
apiCallAttemptTimeout()
to enforce both a timeout on each individual HTTP request (i.e. each retry) and the total time spent on all requests across retries (i.e. the 'api call' time).
-
apiCallAttemptTimeout
public Optional<Duration> apiCallAttemptTimeout()
The amount of time to wait for the http request to complete before giving up and timing out. This value should always be positive, if present.The request timeout feature doesn't have strict guarantees on how quickly a request is aborted when the timeout is breached. The typical case aborts the request within a few milliseconds but there may occasionally be requests that don't get aborted until several seconds after the timer has been breached. Because of this, the request timeout feature should not be used when absolute precision is needed.
This may be used together with
apiCallTimeout()
to enforce both a timeout on each individual HTTP request (i.e. each retry) and the total time spent on all requests across retries (i.e. the 'api call' time).
-
signer
public Optional<Signer> signer()
- Returns:
- the signer for signing the request. This signer get priority over the signer set on the client while signing the requests. If this value is not set, then the client level signer is used for signing the request.
-
metricPublishers
public List<MetricPublisher> metricPublishers()
Return the metric publishers for publishing the metrics collected for this request. This list supersedes the metric publishers set on the client.
-
plugins
public List<SdkPlugin> plugins()
Return the plugins that will be used to update the configuration used by the request.
-
executionAttributes
public ExecutionAttributes executionAttributes()
Returns the additional execution attributes to be added to this request. This collection of attributes is added in addition to the attributes set on the client. An attribute value added on the client within the collection of attributes is superseded by an attribute value added on the request.
-
endpointProvider
public Optional<EndpointProvider> endpointProvider()
Returns the endpoint provider for resolving the endpoint for this request. This supersedes the endpoint provider set on the client.
-
compressionConfiguration
public Optional<CompressionConfiguration> compressionConfiguration()
Returns the compression configuration object, if present, which includes options to enable/disable compression and set the minimum compression threshold. This compression config object supersedes the compression config object set on the client.
-
toBuilder
public abstract RequestOverrideConfiguration.Builder<? extends RequestOverrideConfiguration.Builder> toBuilder()
Create aRequestOverrideConfiguration.Builder
initialized with the properties of thisSdkRequestOverrideConfiguration
.- Returns:
- A new builder intialized with this config's properties.
-
-