Class AwsXmlErrorProtocolUnmarshaller
java.lang.Object
software.amazon.awssdk.protocols.query.unmarshall.AwsXmlErrorProtocolUnmarshaller
- All Implemented Interfaces:
HttpResponseHandler<AwsServiceException>
@SdkProtectedApi
public final class AwsXmlErrorProtocolUnmarshaller
extends Object
implements HttpResponseHandler<AwsServiceException>
Error unmarshaller for Query/EC2/XML based protocols. Some examples of error responses from
the various protocols are below.
Legacy Query (SimpleDB/EC2)
<Response>
<Errors>
<Error>
<Code>MissingParameter</Code>
<Message>The request must contain the parameter DomainName</Message>
<BoxUsage>0.0055590278</BoxUsage>
</Error>
</Errors>
<RequestID>ad3280dd-5ac1-efd1-b9b0-a86969a9234d</RequestID>
</Response>
Traditional Query/Rest-XML (Cloudfront)
<ErrorResponse xmlns="http://cloudfront.amazonaws.com/doc/2017-10-30/">
<Error>
<Type>Sender</Type>
<Code>MalformedInput</Code>
<Message>Invalid XML document</Message>
</Error>
<RequestId>7c8da4af-de44-11e8-a60e-1b2014315455</RequestId>
</ErrorResponse>
Amazon S3
<Error>
<Code>NoSuchBucket</Code>
<Message>The specified bucket does not exist</Message>
<BucketName>flajdfadjfladjf</BucketName>
<RequestId>D9DBB9F267849CA3</RequestId>
<HostId>fn8B1fUvWzg7I3CIeMT4UMqCZDF4+QO1JlbOJlQAVOosACZsLWv/K2dapVncz34a2mArhp11PjI=</HostId>
</Error>
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface software.amazon.awssdk.core.http.HttpResponseHandler
X_AMZ_ID_2_HEADER, X_AMZN_REQUEST_ID_HEADER, X_AMZN_REQUEST_ID_HEADER_ALTERNATE, X_AMZN_REQUEST_ID_HEADERS -
Method Summary
Modifier and TypeMethodDescriptionbuilder()handle(SdkHttpFullResponse response, ExecutionAttributes executionAttributes) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface software.amazon.awssdk.core.http.HttpResponseHandler
needsConnectionLeftOpen
-
Method Details
-
handle
public AwsServiceException handle(SdkHttpFullResponse response, ExecutionAttributes executionAttributes) - Specified by:
handlein interfaceHttpResponseHandler<AwsServiceException>
-
builder
- Returns:
- New Builder instance.
-