diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3HttpLabelBucketFilterIntegration.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3HttpLabelBucketFilterIntegration.java new file mode 100644 index 00000000000..828174da3b8 --- /dev/null +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3HttpLabelBucketFilterIntegration.java @@ -0,0 +1,26 @@ +package software.amazon.smithy.aws.go.codegen.customization; + +import software.amazon.smithy.go.codegen.GoSettings; +import software.amazon.smithy.go.codegen.integration.GoIntegration; +import software.amazon.smithy.model.Model; +import software.amazon.smithy.model.traits.HttpLabelTrait; +import software.amazon.smithy.model.transform.ModelTransformer; + +public class S3HttpLabelBucketFilterIntegration implements GoIntegration { + + @Override + public Model preprocessModel(Model model, GoSettings settings) { + if (!S3ModelUtils.isServiceS3(model, settings.getService(model))) { + return model; + } + + return ModelTransformer.create().removeTraitsIf(model, (shape, trait) -> { + if (trait instanceof HttpLabelTrait) { + return shape.asMemberShape() + .map(s -> s.getMemberName().equals("Bucket")) + .orElse(false); + } + return false; + }); + } +} diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3UpdateEndpoint.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3UpdateEndpoint.java index 03393633277..14707f8081c 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3UpdateEndpoint.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/S3UpdateEndpoint.java @@ -135,20 +135,6 @@ public void processFinalizedModel(GoSettings settings, Model model) { symbolProvider.toSymbol(operation).getName(), UPDATE_ENDPOINT_INTERNAL_ADDER ); - - runtimeClientPlugins.add(RuntimeClientPlugin.builder() - .operationPredicate((m, s, o) -> { - if (!isS3SharedService(m, s)) { - return false; - } - return o.equals(operation); - }) - .registerMiddleware(MiddlewareRegistrar.builder() - .resolvedFunction(SymbolUtils.createValueSymbolBuilder(helperFuncName) - .build()) - .useClientOptions() - .build()) - .build()); } } diff --git a/codegen/smithy-aws-go-codegen/src/main/resources/META-INF/services/software.amazon.smithy.go.codegen.integration.GoIntegration b/codegen/smithy-aws-go-codegen/src/main/resources/META-INF/services/software.amazon.smithy.go.codegen.integration.GoIntegration index c7577598e28..2a4a2bfd1b7 100644 --- a/codegen/smithy-aws-go-codegen/src/main/resources/META-INF/services/software.amazon.smithy.go.codegen.integration.GoIntegration +++ b/codegen/smithy-aws-go-codegen/src/main/resources/META-INF/services/software.amazon.smithy.go.codegen.integration.GoIntegration @@ -55,4 +55,5 @@ software.amazon.smithy.aws.go.codegen.AwsEndpointResolverBuiltInGenerator software.amazon.smithy.aws.go.codegen.customization.S3ControlHostPrefixAccountIdFilterIntegration software.amazon.smithy.aws.go.codegen.customization.S3HttpPathBucketFilterIntegration software.amazon.smithy.aws.go.codegen.customization.S3HostPrefixRequestRouteFilterIntegration +software.amazon.smithy.aws.go.codegen.customization.S3HttpLabelBucketFilterIntegration software.amazon.smithy.aws.go.codegen.AwsEndpointAuthSchemeGenerator \ No newline at end of file diff --git a/service/s3/api_op_AbortMultipartUpload.go b/service/s3/api_op_AbortMultipartUpload.go index eda53ee4349..8ede0847fd0 100644 --- a/service/s3/api_op_AbortMultipartUpload.go +++ b/service/s3/api_op_AbortMultipartUpload.go @@ -169,9 +169,6 @@ func (c *Client) addOperationAbortMultipartUploadMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addAbortMultipartUploadUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_CompleteMultipartUpload.go b/service/s3/api_op_CompleteMultipartUpload.go index f608444185a..519daa5b6ae 100644 --- a/service/s3/api_op_CompleteMultipartUpload.go +++ b/service/s3/api_op_CompleteMultipartUpload.go @@ -338,9 +338,6 @@ func (c *Client) addOperationCompleteMultipartUploadMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCompleteMultipartUploadUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_CopyObject.go b/service/s3/api_op_CopyObject.go index 7294c9c6a6d..7ec9bce60d3 100644 --- a/service/s3/api_op_CopyObject.go +++ b/service/s3/api_op_CopyObject.go @@ -510,9 +510,6 @@ func (c *Client) addOperationCopyObjectMiddlewares(stack *middleware.Stack, opti if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCopyObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_CreateBucket.go b/service/s3/api_op_CreateBucket.go index 438025e5004..62e8656b62c 100644 --- a/service/s3/api_op_CreateBucket.go +++ b/service/s3/api_op_CreateBucket.go @@ -216,9 +216,6 @@ func (c *Client) addOperationCreateBucketMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_CreateMultipartUpload.go b/service/s3/api_op_CreateMultipartUpload.go index 5fab020de18..b73401dde75 100644 --- a/service/s3/api_op_CreateMultipartUpload.go +++ b/service/s3/api_op_CreateMultipartUpload.go @@ -490,9 +490,6 @@ func (c *Client) addOperationCreateMultipartUploadMiddlewares(stack *middleware. if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateMultipartUploadUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucket.go b/service/s3/api_op_DeleteBucket.go index aaeaf0016c4..507a0f9f0af 100644 --- a/service/s3/api_op_DeleteBucket.go +++ b/service/s3/api_op_DeleteBucket.go @@ -120,9 +120,6 @@ func (c *Client) addOperationDeleteBucketMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketAnalyticsConfiguration.go b/service/s3/api_op_DeleteBucketAnalyticsConfiguration.go index 039c56cf97c..eb0904042a4 100644 --- a/service/s3/api_op_DeleteBucketAnalyticsConfiguration.go +++ b/service/s3/api_op_DeleteBucketAnalyticsConfiguration.go @@ -133,9 +133,6 @@ func (c *Client) addOperationDeleteBucketAnalyticsConfigurationMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketAnalyticsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketCors.go b/service/s3/api_op_DeleteBucketCors.go index 717e36eb753..f82a2d1774a 100644 --- a/service/s3/api_op_DeleteBucketCors.go +++ b/service/s3/api_op_DeleteBucketCors.go @@ -122,9 +122,6 @@ func (c *Client) addOperationDeleteBucketCorsMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketCorsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketEncryption.go b/service/s3/api_op_DeleteBucketEncryption.go index 9fc20c1349b..8a5661e5338 100644 --- a/service/s3/api_op_DeleteBucketEncryption.go +++ b/service/s3/api_op_DeleteBucketEncryption.go @@ -130,9 +130,6 @@ func (c *Client) addOperationDeleteBucketEncryptionMiddlewares(stack *middleware if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketEncryptionUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketIntelligentTieringConfiguration.go b/service/s3/api_op_DeleteBucketIntelligentTieringConfiguration.go index b142849fa7c..5a4120039e4 100644 --- a/service/s3/api_op_DeleteBucketIntelligentTieringConfiguration.go +++ b/service/s3/api_op_DeleteBucketIntelligentTieringConfiguration.go @@ -134,9 +134,6 @@ func (c *Client) addOperationDeleteBucketIntelligentTieringConfigurationMiddlewa if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketIntelligentTieringConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketInventoryConfiguration.go b/service/s3/api_op_DeleteBucketInventoryConfiguration.go index 1a77bee7f1d..145e2a30e15 100644 --- a/service/s3/api_op_DeleteBucketInventoryConfiguration.go +++ b/service/s3/api_op_DeleteBucketInventoryConfiguration.go @@ -132,9 +132,6 @@ func (c *Client) addOperationDeleteBucketInventoryConfigurationMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketInventoryConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketLifecycle.go b/service/s3/api_op_DeleteBucketLifecycle.go index f9014116164..40e44b74828 100644 --- a/service/s3/api_op_DeleteBucketLifecycle.go +++ b/service/s3/api_op_DeleteBucketLifecycle.go @@ -128,9 +128,6 @@ func (c *Client) addOperationDeleteBucketLifecycleMiddlewares(stack *middleware. if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketLifecycleUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketMetricsConfiguration.go b/service/s3/api_op_DeleteBucketMetricsConfiguration.go index 8cfa78c9fb8..56d885ecaff 100644 --- a/service/s3/api_op_DeleteBucketMetricsConfiguration.go +++ b/service/s3/api_op_DeleteBucketMetricsConfiguration.go @@ -136,9 +136,6 @@ func (c *Client) addOperationDeleteBucketMetricsConfigurationMiddlewares(stack * if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketMetricsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketOwnershipControls.go b/service/s3/api_op_DeleteBucketOwnershipControls.go index 8f6f9e1c2c0..aa8801e12db 100644 --- a/service/s3/api_op_DeleteBucketOwnershipControls.go +++ b/service/s3/api_op_DeleteBucketOwnershipControls.go @@ -122,9 +122,6 @@ func (c *Client) addOperationDeleteBucketOwnershipControlsMiddlewares(stack *mid if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketOwnershipControlsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketPolicy.go b/service/s3/api_op_DeleteBucketPolicy.go index ec93b6db34e..3ccb940cd99 100644 --- a/service/s3/api_op_DeleteBucketPolicy.go +++ b/service/s3/api_op_DeleteBucketPolicy.go @@ -134,9 +134,6 @@ func (c *Client) addOperationDeleteBucketPolicyMiddlewares(stack *middleware.Sta if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketReplication.go b/service/s3/api_op_DeleteBucketReplication.go index 97d6524441b..b1cf7f45311 100644 --- a/service/s3/api_op_DeleteBucketReplication.go +++ b/service/s3/api_op_DeleteBucketReplication.go @@ -127,9 +127,6 @@ func (c *Client) addOperationDeleteBucketReplicationMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketTagging.go b/service/s3/api_op_DeleteBucketTagging.go index 18b51d992b2..a0138000aaa 100644 --- a/service/s3/api_op_DeleteBucketTagging.go +++ b/service/s3/api_op_DeleteBucketTagging.go @@ -121,9 +121,6 @@ func (c *Client) addOperationDeleteBucketTaggingMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteBucketWebsite.go b/service/s3/api_op_DeleteBucketWebsite.go index 865928c1ced..59a7c8f7120 100644 --- a/service/s3/api_op_DeleteBucketWebsite.go +++ b/service/s3/api_op_DeleteBucketWebsite.go @@ -129,9 +129,6 @@ func (c *Client) addOperationDeleteBucketWebsiteMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketWebsiteUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteObject.go b/service/s3/api_op_DeleteObject.go index 553ca03e0fe..f909bf8819a 100644 --- a/service/s3/api_op_DeleteObject.go +++ b/service/s3/api_op_DeleteObject.go @@ -188,9 +188,6 @@ func (c *Client) addOperationDeleteObjectMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteObjectTagging.go b/service/s3/api_op_DeleteObjectTagging.go index c385e86a8dd..bc435c0a2e5 100644 --- a/service/s3/api_op_DeleteObjectTagging.go +++ b/service/s3/api_op_DeleteObjectTagging.go @@ -150,9 +150,6 @@ func (c *Client) addOperationDeleteObjectTaggingMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteObjectTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeleteObjects.go b/service/s3/api_op_DeleteObjects.go index a1bf9c312ec..20759ad7d11 100644 --- a/service/s3/api_op_DeleteObjects.go +++ b/service/s3/api_op_DeleteObjects.go @@ -212,9 +212,6 @@ func (c *Client) addOperationDeleteObjectsMiddlewares(stack *middleware.Stack, o if err = addDeleteObjectsInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addDeleteObjectsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_DeletePublicAccessBlock.go b/service/s3/api_op_DeletePublicAccessBlock.go index a430ac318d5..4513e68a397 100644 --- a/service/s3/api_op_DeletePublicAccessBlock.go +++ b/service/s3/api_op_DeletePublicAccessBlock.go @@ -125,9 +125,6 @@ func (c *Client) addOperationDeletePublicAccessBlockMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeletePublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketAccelerateConfiguration.go b/service/s3/api_op_GetBucketAccelerateConfiguration.go index a088be7bdf3..8ba7c35b32e 100644 --- a/service/s3/api_op_GetBucketAccelerateConfiguration.go +++ b/service/s3/api_op_GetBucketAccelerateConfiguration.go @@ -150,9 +150,6 @@ func (c *Client) addOperationGetBucketAccelerateConfigurationMiddlewares(stack * if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketAccelerateConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketAcl.go b/service/s3/api_op_GetBucketAcl.go index f0c10b477fe..4a3f6eb3888 100644 --- a/service/s3/api_op_GetBucketAcl.go +++ b/service/s3/api_op_GetBucketAcl.go @@ -149,9 +149,6 @@ func (c *Client) addOperationGetBucketAclMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketAclUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketAnalyticsConfiguration.go b/service/s3/api_op_GetBucketAnalyticsConfiguration.go index 4e8c8a5fa15..d834fea26c3 100644 --- a/service/s3/api_op_GetBucketAnalyticsConfiguration.go +++ b/service/s3/api_op_GetBucketAnalyticsConfiguration.go @@ -139,9 +139,6 @@ func (c *Client) addOperationGetBucketAnalyticsConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketAnalyticsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketCors.go b/service/s3/api_op_GetBucketCors.go index ee6f1be463d..8360b7d48c3 100644 --- a/service/s3/api_op_GetBucketCors.go +++ b/service/s3/api_op_GetBucketCors.go @@ -142,9 +142,6 @@ func (c *Client) addOperationGetBucketCorsMiddlewares(stack *middleware.Stack, o if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketCorsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketEncryption.go b/service/s3/api_op_GetBucketEncryption.go index d193a6471ee..3702151be77 100644 --- a/service/s3/api_op_GetBucketEncryption.go +++ b/service/s3/api_op_GetBucketEncryption.go @@ -135,9 +135,6 @@ func (c *Client) addOperationGetBucketEncryptionMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketEncryptionUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketIntelligentTieringConfiguration.go b/service/s3/api_op_GetBucketIntelligentTieringConfiguration.go index e2ce639ea6c..eb7402711f2 100644 --- a/service/s3/api_op_GetBucketIntelligentTieringConfiguration.go +++ b/service/s3/api_op_GetBucketIntelligentTieringConfiguration.go @@ -139,9 +139,6 @@ func (c *Client) addOperationGetBucketIntelligentTieringConfigurationMiddlewares if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketIntelligentTieringConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketInventoryConfiguration.go b/service/s3/api_op_GetBucketInventoryConfiguration.go index 51968f9549b..90f395e83a1 100644 --- a/service/s3/api_op_GetBucketInventoryConfiguration.go +++ b/service/s3/api_op_GetBucketInventoryConfiguration.go @@ -136,9 +136,6 @@ func (c *Client) addOperationGetBucketInventoryConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketInventoryConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketLifecycleConfiguration.go b/service/s3/api_op_GetBucketLifecycleConfiguration.go index 13323e36dfa..c5dc7113e14 100644 --- a/service/s3/api_op_GetBucketLifecycleConfiguration.go +++ b/service/s3/api_op_GetBucketLifecycleConfiguration.go @@ -145,9 +145,6 @@ func (c *Client) addOperationGetBucketLifecycleConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketLifecycleConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketLocation.go b/service/s3/api_op_GetBucketLocation.go index 255e52f96a0..c41a543daf9 100644 --- a/service/s3/api_op_GetBucketLocation.go +++ b/service/s3/api_op_GetBucketLocation.go @@ -154,9 +154,6 @@ func (c *Client) addOperationGetBucketLocationMiddlewares(stack *middleware.Stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketLocationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketLogging.go b/service/s3/api_op_GetBucketLogging.go index 893531b68e4..772d06a687f 100644 --- a/service/s3/api_op_GetBucketLogging.go +++ b/service/s3/api_op_GetBucketLogging.go @@ -127,9 +127,6 @@ func (c *Client) addOperationGetBucketLoggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketLoggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketMetricsConfiguration.go b/service/s3/api_op_GetBucketMetricsConfiguration.go index 21a68461c8a..454c63d18c2 100644 --- a/service/s3/api_op_GetBucketMetricsConfiguration.go +++ b/service/s3/api_op_GetBucketMetricsConfiguration.go @@ -141,9 +141,6 @@ func (c *Client) addOperationGetBucketMetricsConfigurationMiddlewares(stack *mid if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketMetricsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketNotificationConfiguration.go b/service/s3/api_op_GetBucketNotificationConfiguration.go index 051258ba86d..3d576330301 100644 --- a/service/s3/api_op_GetBucketNotificationConfiguration.go +++ b/service/s3/api_op_GetBucketNotificationConfiguration.go @@ -158,9 +158,6 @@ func (c *Client) addOperationGetBucketNotificationConfigurationMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketNotificationConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketOwnershipControls.go b/service/s3/api_op_GetBucketOwnershipControls.go index cf82c2bd174..7f224725025 100644 --- a/service/s3/api_op_GetBucketOwnershipControls.go +++ b/service/s3/api_op_GetBucketOwnershipControls.go @@ -128,9 +128,6 @@ func (c *Client) addOperationGetBucketOwnershipControlsMiddlewares(stack *middle if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketOwnershipControlsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketPolicy.go b/service/s3/api_op_GetBucketPolicy.go index d4d8ebc911a..f56cf204d42 100644 --- a/service/s3/api_op_GetBucketPolicy.go +++ b/service/s3/api_op_GetBucketPolicy.go @@ -150,9 +150,6 @@ func (c *Client) addOperationGetBucketPolicyMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketPolicyStatus.go b/service/s3/api_op_GetBucketPolicyStatus.go index 40288d0e4a5..7a19718ede8 100644 --- a/service/s3/api_op_GetBucketPolicyStatus.go +++ b/service/s3/api_op_GetBucketPolicyStatus.go @@ -131,9 +131,6 @@ func (c *Client) addOperationGetBucketPolicyStatusMiddlewares(stack *middleware. if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketPolicyStatusUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketReplication.go b/service/s3/api_op_GetBucketReplication.go index e57390a4835..46a03580758 100644 --- a/service/s3/api_op_GetBucketReplication.go +++ b/service/s3/api_op_GetBucketReplication.go @@ -135,9 +135,6 @@ func (c *Client) addOperationGetBucketReplicationMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketRequestPayment.go b/service/s3/api_op_GetBucketRequestPayment.go index c9c92e09190..a9f199cf517 100644 --- a/service/s3/api_op_GetBucketRequestPayment.go +++ b/service/s3/api_op_GetBucketRequestPayment.go @@ -125,9 +125,6 @@ func (c *Client) addOperationGetBucketRequestPaymentMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketRequestPaymentUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketTagging.go b/service/s3/api_op_GetBucketTagging.go index 7b4b154ceb5..cbe5e8c4b7f 100644 --- a/service/s3/api_op_GetBucketTagging.go +++ b/service/s3/api_op_GetBucketTagging.go @@ -132,9 +132,6 @@ func (c *Client) addOperationGetBucketTaggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketVersioning.go b/service/s3/api_op_GetBucketVersioning.go index 9ad9ace3d16..0af725a4fb0 100644 --- a/service/s3/api_op_GetBucketVersioning.go +++ b/service/s3/api_op_GetBucketVersioning.go @@ -133,9 +133,6 @@ func (c *Client) addOperationGetBucketVersioningMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketVersioningUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetBucketWebsite.go b/service/s3/api_op_GetBucketWebsite.go index dbe6cdfd9a5..932d13b0081 100644 --- a/service/s3/api_op_GetBucketWebsite.go +++ b/service/s3/api_op_GetBucketWebsite.go @@ -140,9 +140,6 @@ func (c *Client) addOperationGetBucketWebsiteMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketWebsiteUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObject.go b/service/s3/api_op_GetObject.go index ba323a96c16..a4507f517d1 100644 --- a/service/s3/api_op_GetObject.go +++ b/service/s3/api_op_GetObject.go @@ -457,9 +457,6 @@ func (c *Client) addOperationGetObjectMiddlewares(stack *middleware.Stack, optio if err = addGetObjectOutputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addGetObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectAcl.go b/service/s3/api_op_GetObjectAcl.go index ddd1bc9194d..1965df0b023 100644 --- a/service/s3/api_op_GetObjectAcl.go +++ b/service/s3/api_op_GetObjectAcl.go @@ -166,9 +166,6 @@ func (c *Client) addOperationGetObjectAclMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectAclUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectAttributes.go b/service/s3/api_op_GetObjectAttributes.go index aea20035b54..23057c98652 100644 --- a/service/s3/api_op_GetObjectAttributes.go +++ b/service/s3/api_op_GetObjectAttributes.go @@ -268,9 +268,6 @@ func (c *Client) addOperationGetObjectAttributesMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectAttributesUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectLegalHold.go b/service/s3/api_op_GetObjectLegalHold.go index 7e95cbb5799..3b2792c60e4 100644 --- a/service/s3/api_op_GetObjectLegalHold.go +++ b/service/s3/api_op_GetObjectLegalHold.go @@ -147,9 +147,6 @@ func (c *Client) addOperationGetObjectLegalHoldMiddlewares(stack *middleware.Sta if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectLegalHoldUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectLockConfiguration.go b/service/s3/api_op_GetObjectLockConfiguration.go index 2033ee70ea9..8dae7abe108 100644 --- a/service/s3/api_op_GetObjectLockConfiguration.go +++ b/service/s3/api_op_GetObjectLockConfiguration.go @@ -132,9 +132,6 @@ func (c *Client) addOperationGetObjectLockConfigurationMiddlewares(stack *middle if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectLockConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectRetention.go b/service/s3/api_op_GetObjectRetention.go index c30ba11dbd2..bc5ec2f526e 100644 --- a/service/s3/api_op_GetObjectRetention.go +++ b/service/s3/api_op_GetObjectRetention.go @@ -147,9 +147,6 @@ func (c *Client) addOperationGetObjectRetentionMiddlewares(stack *middleware.Sta if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectRetentionUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectTagging.go b/service/s3/api_op_GetObjectTagging.go index 57df21527d8..d4055128923 100644 --- a/service/s3/api_op_GetObjectTagging.go +++ b/service/s3/api_op_GetObjectTagging.go @@ -167,9 +167,6 @@ func (c *Client) addOperationGetObjectTaggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetObjectTorrent.go b/service/s3/api_op_GetObjectTorrent.go index e6ca6bb7843..09ff69c2c41 100644 --- a/service/s3/api_op_GetObjectTorrent.go +++ b/service/s3/api_op_GetObjectTorrent.go @@ -141,9 +141,6 @@ func (c *Client) addOperationGetObjectTorrentMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetObjectTorrentUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_GetPublicAccessBlock.go b/service/s3/api_op_GetPublicAccessBlock.go index 30a4771214e..752071d91dc 100644 --- a/service/s3/api_op_GetPublicAccessBlock.go +++ b/service/s3/api_op_GetPublicAccessBlock.go @@ -138,9 +138,6 @@ func (c *Client) addOperationGetPublicAccessBlockMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetPublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_HeadBucket.go b/service/s3/api_op_HeadBucket.go index b42a8a48788..3768897ae88 100644 --- a/service/s3/api_op_HeadBucket.go +++ b/service/s3/api_op_HeadBucket.go @@ -160,9 +160,6 @@ func (c *Client) addOperationHeadBucketMiddlewares(stack *middleware.Stack, opti if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addHeadBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_HeadObject.go b/service/s3/api_op_HeadObject.go index 21ad09b1dd8..ab31eea912e 100644 --- a/service/s3/api_op_HeadObject.go +++ b/service/s3/api_op_HeadObject.go @@ -440,9 +440,6 @@ func (c *Client) addOperationHeadObjectMiddlewares(stack *middleware.Stack, opti if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addHeadObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListBucketAnalyticsConfigurations.go b/service/s3/api_op_ListBucketAnalyticsConfigurations.go index 00015355191..36439d1383e 100644 --- a/service/s3/api_op_ListBucketAnalyticsConfigurations.go +++ b/service/s3/api_op_ListBucketAnalyticsConfigurations.go @@ -158,9 +158,6 @@ func (c *Client) addOperationListBucketAnalyticsConfigurationsMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListBucketAnalyticsConfigurationsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListBucketIntelligentTieringConfigurations.go b/service/s3/api_op_ListBucketIntelligentTieringConfigurations.go index be67cb9e310..1191be2d004 100644 --- a/service/s3/api_op_ListBucketIntelligentTieringConfigurations.go +++ b/service/s3/api_op_ListBucketIntelligentTieringConfigurations.go @@ -152,9 +152,6 @@ func (c *Client) addOperationListBucketIntelligentTieringConfigurationsMiddlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListBucketIntelligentTieringConfigurationsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListBucketInventoryConfigurations.go b/service/s3/api_op_ListBucketInventoryConfigurations.go index b2ed4f87f34..6adc7576a4b 100644 --- a/service/s3/api_op_ListBucketInventoryConfigurations.go +++ b/service/s3/api_op_ListBucketInventoryConfigurations.go @@ -159,9 +159,6 @@ func (c *Client) addOperationListBucketInventoryConfigurationsMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListBucketInventoryConfigurationsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListBucketMetricsConfigurations.go b/service/s3/api_op_ListBucketMetricsConfigurations.go index 852b11511d3..1595fece4a2 100644 --- a/service/s3/api_op_ListBucketMetricsConfigurations.go +++ b/service/s3/api_op_ListBucketMetricsConfigurations.go @@ -162,9 +162,6 @@ func (c *Client) addOperationListBucketMetricsConfigurationsMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListBucketMetricsConfigurationsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListBuckets.go b/service/s3/api_op_ListBuckets.go index 1e3ba8a4cb9..e70e156052a 100644 --- a/service/s3/api_op_ListBuckets.go +++ b/service/s3/api_op_ListBuckets.go @@ -114,9 +114,6 @@ func (c *Client) addOperationListBucketsMiddlewares(stack *middleware.Stack, opt if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListBucketsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListMultipartUploads.go b/service/s3/api_op_ListMultipartUploads.go index 6798aa68253..9f330cf5a78 100644 --- a/service/s3/api_op_ListMultipartUploads.go +++ b/service/s3/api_op_ListMultipartUploads.go @@ -259,9 +259,6 @@ func (c *Client) addOperationListMultipartUploadsMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListMultipartUploadsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListObjectVersions.go b/service/s3/api_op_ListObjectVersions.go index 8698fc84848..23a267693ca 100644 --- a/service/s3/api_op_ListObjectVersions.go +++ b/service/s3/api_op_ListObjectVersions.go @@ -236,9 +236,6 @@ func (c *Client) addOperationListObjectVersionsMiddlewares(stack *middleware.Sta if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListObjectVersionsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListObjects.go b/service/s3/api_op_ListObjects.go index 4d23066d107..e48eb96e97b 100644 --- a/service/s3/api_op_ListObjects.go +++ b/service/s3/api_op_ListObjects.go @@ -231,9 +231,6 @@ func (c *Client) addOperationListObjectsMiddlewares(stack *middleware.Stack, opt if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListObjectsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListObjectsV2.go b/service/s3/api_op_ListObjectsV2.go index 7075b902532..a1e7be08505 100644 --- a/service/s3/api_op_ListObjectsV2.go +++ b/service/s3/api_op_ListObjectsV2.go @@ -266,9 +266,6 @@ func (c *Client) addOperationListObjectsV2Middlewares(stack *middleware.Stack, o if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListObjectsV2UpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_ListParts.go b/service/s3/api_op_ListParts.go index 7bc7a675a3c..a0ac0e3c744 100644 --- a/service/s3/api_op_ListParts.go +++ b/service/s3/api_op_ListParts.go @@ -265,9 +265,6 @@ func (c *Client) addOperationListPartsMiddlewares(stack *middleware.Stack, optio if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListPartsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketAccelerateConfiguration.go b/service/s3/api_op_PutBucketAccelerateConfiguration.go index f4848f3c1e2..6e64604c802 100644 --- a/service/s3/api_op_PutBucketAccelerateConfiguration.go +++ b/service/s3/api_op_PutBucketAccelerateConfiguration.go @@ -158,9 +158,6 @@ func (c *Client) addOperationPutBucketAccelerateConfigurationMiddlewares(stack * if err = addPutBucketAccelerateConfigurationInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketAccelerateConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketAcl.go b/service/s3/api_op_PutBucketAcl.go index 578c6cd867a..580db243e3a 100644 --- a/service/s3/api_op_PutBucketAcl.go +++ b/service/s3/api_op_PutBucketAcl.go @@ -243,9 +243,6 @@ func (c *Client) addOperationPutBucketAclMiddlewares(stack *middleware.Stack, op if err = addPutBucketAclInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketAclUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketAnalyticsConfiguration.go b/service/s3/api_op_PutBucketAnalyticsConfiguration.go index 7ad507b3dd0..2a00af2dd21 100644 --- a/service/s3/api_op_PutBucketAnalyticsConfiguration.go +++ b/service/s3/api_op_PutBucketAnalyticsConfiguration.go @@ -165,9 +165,6 @@ func (c *Client) addOperationPutBucketAnalyticsConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketAnalyticsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketCors.go b/service/s3/api_op_PutBucketCors.go index 939ea0d74b0..1d628fd586f 100644 --- a/service/s3/api_op_PutBucketCors.go +++ b/service/s3/api_op_PutBucketCors.go @@ -172,9 +172,6 @@ func (c *Client) addOperationPutBucketCorsMiddlewares(stack *middleware.Stack, o if err = addPutBucketCorsInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketCorsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketEncryption.go b/service/s3/api_op_PutBucketEncryption.go index e1307c26d85..03d7d761071 100644 --- a/service/s3/api_op_PutBucketEncryption.go +++ b/service/s3/api_op_PutBucketEncryption.go @@ -173,9 +173,6 @@ func (c *Client) addOperationPutBucketEncryptionMiddlewares(stack *middleware.St if err = addPutBucketEncryptionInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketEncryptionUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketIntelligentTieringConfiguration.go b/service/s3/api_op_PutBucketIntelligentTieringConfiguration.go index 05c0d438e4f..1f2c37e2ea0 100644 --- a/service/s3/api_op_PutBucketIntelligentTieringConfiguration.go +++ b/service/s3/api_op_PutBucketIntelligentTieringConfiguration.go @@ -152,9 +152,6 @@ func (c *Client) addOperationPutBucketIntelligentTieringConfigurationMiddlewares if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketIntelligentTieringConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketInventoryConfiguration.go b/service/s3/api_op_PutBucketInventoryConfiguration.go index 1f6bb1985f5..e1bf01ab85a 100644 --- a/service/s3/api_op_PutBucketInventoryConfiguration.go +++ b/service/s3/api_op_PutBucketInventoryConfiguration.go @@ -168,9 +168,6 @@ func (c *Client) addOperationPutBucketInventoryConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketInventoryConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketLifecycleConfiguration.go b/service/s3/api_op_PutBucketLifecycleConfiguration.go index ce98a47a6b5..1b5dba2f6c2 100644 --- a/service/s3/api_op_PutBucketLifecycleConfiguration.go +++ b/service/s3/api_op_PutBucketLifecycleConfiguration.go @@ -183,9 +183,6 @@ func (c *Client) addOperationPutBucketLifecycleConfigurationMiddlewares(stack *m if err = addPutBucketLifecycleConfigurationInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketLifecycleConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketLogging.go b/service/s3/api_op_PutBucketLogging.go index afda1f945b2..0b12a29e4f2 100644 --- a/service/s3/api_op_PutBucketLogging.go +++ b/service/s3/api_op_PutBucketLogging.go @@ -173,9 +173,6 @@ func (c *Client) addOperationPutBucketLoggingMiddlewares(stack *middleware.Stack if err = addPutBucketLoggingInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketLoggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketMetricsConfiguration.go b/service/s3/api_op_PutBucketMetricsConfiguration.go index d5b2b4fd3be..6eb7e5aee28 100644 --- a/service/s3/api_op_PutBucketMetricsConfiguration.go +++ b/service/s3/api_op_PutBucketMetricsConfiguration.go @@ -149,9 +149,6 @@ func (c *Client) addOperationPutBucketMetricsConfigurationMiddlewares(stack *mid if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketMetricsConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketNotificationConfiguration.go b/service/s3/api_op_PutBucketNotificationConfiguration.go index b2f13e041f6..5e757ca99bf 100644 --- a/service/s3/api_op_PutBucketNotificationConfiguration.go +++ b/service/s3/api_op_PutBucketNotificationConfiguration.go @@ -160,9 +160,6 @@ func (c *Client) addOperationPutBucketNotificationConfigurationMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketNotificationConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketOwnershipControls.go b/service/s3/api_op_PutBucketOwnershipControls.go index e01ab8cdff4..e76b27b159a 100644 --- a/service/s3/api_op_PutBucketOwnershipControls.go +++ b/service/s3/api_op_PutBucketOwnershipControls.go @@ -138,9 +138,6 @@ func (c *Client) addOperationPutBucketOwnershipControlsMiddlewares(stack *middle if err = addPutBucketOwnershipControlsInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketOwnershipControlsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketPolicy.go b/service/s3/api_op_PutBucketPolicy.go index 3eff75c8348..085c5f9e8a4 100644 --- a/service/s3/api_op_PutBucketPolicy.go +++ b/service/s3/api_op_PutBucketPolicy.go @@ -162,9 +162,6 @@ func (c *Client) addOperationPutBucketPolicyMiddlewares(stack *middleware.Stack, if err = addPutBucketPolicyInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketReplication.go b/service/s3/api_op_PutBucketReplication.go index 13cad9a32ac..dc843aa1d3a 100644 --- a/service/s3/api_op_PutBucketReplication.go +++ b/service/s3/api_op_PutBucketReplication.go @@ -185,9 +185,6 @@ func (c *Client) addOperationPutBucketReplicationMiddlewares(stack *middleware.S if err = addPutBucketReplicationInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketRequestPayment.go b/service/s3/api_op_PutBucketRequestPayment.go index bb634469197..c274ad14840 100644 --- a/service/s3/api_op_PutBucketRequestPayment.go +++ b/service/s3/api_op_PutBucketRequestPayment.go @@ -149,9 +149,6 @@ func (c *Client) addOperationPutBucketRequestPaymentMiddlewares(stack *middlewar if err = addPutBucketRequestPaymentInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketRequestPaymentUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketTagging.go b/service/s3/api_op_PutBucketTagging.go index 39ff555233c..7c6785e4f9b 100644 --- a/service/s3/api_op_PutBucketTagging.go +++ b/service/s3/api_op_PutBucketTagging.go @@ -177,9 +177,6 @@ func (c *Client) addOperationPutBucketTaggingMiddlewares(stack *middleware.Stack if err = addPutBucketTaggingInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketVersioning.go b/service/s3/api_op_PutBucketVersioning.go index e9e6c36b400..17a79a0fa07 100644 --- a/service/s3/api_op_PutBucketVersioning.go +++ b/service/s3/api_op_PutBucketVersioning.go @@ -167,9 +167,6 @@ func (c *Client) addOperationPutBucketVersioningMiddlewares(stack *middleware.St if err = addPutBucketVersioningInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketVersioningUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutBucketWebsite.go b/service/s3/api_op_PutBucketWebsite.go index 87ec865013a..b25f3b08f4b 100644 --- a/service/s3/api_op_PutBucketWebsite.go +++ b/service/s3/api_op_PutBucketWebsite.go @@ -185,9 +185,6 @@ func (c *Client) addOperationPutBucketWebsiteMiddlewares(stack *middleware.Stack if err = addPutBucketWebsiteInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutBucketWebsiteUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObject.go b/service/s3/api_op_PutObject.go index 18c2b1cac14..05834cdf1c9 100644 --- a/service/s3/api_op_PutObject.go +++ b/service/s3/api_op_PutObject.go @@ -487,9 +487,6 @@ func (c *Client) addOperationPutObjectMiddlewares(stack *middleware.Stack, optio if err = addPutObjectInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObjectAcl.go b/service/s3/api_op_PutObjectAcl.go index 175ed514a68..e8389b0c205 100644 --- a/service/s3/api_op_PutObjectAcl.go +++ b/service/s3/api_op_PutObjectAcl.go @@ -287,9 +287,6 @@ func (c *Client) addOperationPutObjectAclMiddlewares(stack *middleware.Stack, op if err = addPutObjectAclInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectAclUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObjectLegalHold.go b/service/s3/api_op_PutObjectLegalHold.go index 448856de39b..77a3cc1e508 100644 --- a/service/s3/api_op_PutObjectLegalHold.go +++ b/service/s3/api_op_PutObjectLegalHold.go @@ -169,9 +169,6 @@ func (c *Client) addOperationPutObjectLegalHoldMiddlewares(stack *middleware.Sta if err = addPutObjectLegalHoldInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectLegalHoldUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObjectLockConfiguration.go b/service/s3/api_op_PutObjectLockConfiguration.go index ba893589994..1ba24963b3e 100644 --- a/service/s3/api_op_PutObjectLockConfiguration.go +++ b/service/s3/api_op_PutObjectLockConfiguration.go @@ -162,9 +162,6 @@ func (c *Client) addOperationPutObjectLockConfigurationMiddlewares(stack *middle if err = addPutObjectLockConfigurationInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectLockConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObjectRetention.go b/service/s3/api_op_PutObjectRetention.go index 3ee854b27c9..007edc21651 100644 --- a/service/s3/api_op_PutObjectRetention.go +++ b/service/s3/api_op_PutObjectRetention.go @@ -176,9 +176,6 @@ func (c *Client) addOperationPutObjectRetentionMiddlewares(stack *middleware.Sta if err = addPutObjectRetentionInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectRetentionUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutObjectTagging.go b/service/s3/api_op_PutObjectTagging.go index 0937dea93c1..1c1bd371ab1 100644 --- a/service/s3/api_op_PutObjectTagging.go +++ b/service/s3/api_op_PutObjectTagging.go @@ -203,9 +203,6 @@ func (c *Client) addOperationPutObjectTaggingMiddlewares(stack *middleware.Stack if err = addPutObjectTaggingInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutObjectTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_PutPublicAccessBlock.go b/service/s3/api_op_PutPublicAccessBlock.go index a6424e31eca..d6260bea674 100644 --- a/service/s3/api_op_PutPublicAccessBlock.go +++ b/service/s3/api_op_PutPublicAccessBlock.go @@ -161,9 +161,6 @@ func (c *Client) addOperationPutPublicAccessBlockMiddlewares(stack *middleware.S if err = addPutPublicAccessBlockInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addPutPublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_RestoreObject.go b/service/s3/api_op_RestoreObject.go index 93cf8c33a31..18eeea964a5 100644 --- a/service/s3/api_op_RestoreObject.go +++ b/service/s3/api_op_RestoreObject.go @@ -319,9 +319,6 @@ func (c *Client) addOperationRestoreObjectMiddlewares(stack *middleware.Stack, o if err = addRestoreObjectInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addRestoreObjectUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_SelectObjectContent.go b/service/s3/api_op_SelectObjectContent.go index fd7bf2c8634..cac11f2198d 100644 --- a/service/s3/api_op_SelectObjectContent.go +++ b/service/s3/api_op_SelectObjectContent.go @@ -246,9 +246,6 @@ func (c *Client) addOperationSelectObjectContentMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addSelectObjectContentUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_UploadPart.go b/service/s3/api_op_UploadPart.go index 08510d2d483..29ed88c3c6a 100644 --- a/service/s3/api_op_UploadPart.go +++ b/service/s3/api_op_UploadPart.go @@ -360,9 +360,6 @@ func (c *Client) addOperationUploadPartMiddlewares(stack *middleware.Stack, opti if err = addUploadPartInputChecksumMiddlewares(stack, options); err != nil { return err } - if err = addUploadPartUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_UploadPartCopy.go b/service/s3/api_op_UploadPartCopy.go index 2b81de13dcf..6656e0af5d3 100644 --- a/service/s3/api_op_UploadPartCopy.go +++ b/service/s3/api_op_UploadPartCopy.go @@ -343,9 +343,6 @@ func (c *Client) addOperationUploadPartCopyMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addUploadPartCopyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/api_op_WriteGetObjectResponse.go b/service/s3/api_op_WriteGetObjectResponse.go index d4bc6882db0..dbb7d4a8632 100644 --- a/service/s3/api_op_WriteGetObjectResponse.go +++ b/service/s3/api_op_WriteGetObjectResponse.go @@ -353,9 +353,6 @@ func (c *Client) addOperationWriteGetObjectResponseMiddlewares(stack *middleware if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addWriteGetObjectResponseUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3/internal/customizations/update_endpoint_test.go b/service/s3/internal/customizations/update_endpoint_test.go index d91775a8c39..c38e39f0a6c 100644 --- a/service/s3/internal/customizations/update_endpoint_test.go +++ b/service/s3/internal/customizations/update_endpoint_test.go @@ -25,7 +25,7 @@ type s3BucketTest struct { err string } -func TestUpdateEndpointBuild(t *testing.T) { +func Test_UpdateEndpointBuild(t *testing.T) { cases := map[string]map[string]struct { tests []s3BucketTest useAccelerate bool @@ -116,7 +116,7 @@ func TestUpdateEndpointBuild(t *testing.T) { }, "VirtualHostStyleBucket": { customEndpoint: &aws.Endpoint{ - URL: "https://example.1region.amazonaws.com", + URL: "https://example.region.amazonaws.com", HostnameImmutable: true, }, tests: []s3BucketTest{ @@ -199,7 +199,6 @@ func TestUpdateEndpointBuild(t *testing.T) { }, ) - // isaiah: ensure the correct error is produced if test.err != "" { if err == nil { t.Fatalf("test %d: expected error, got none", i) @@ -209,14 +208,10 @@ func TestUpdateEndpointBuild(t *testing.T) { } return } - - // isaiah: ensure that no error is produced if err != nil { t.Fatalf("expect no error, got %v", err) } - // isaiah: build a Go request from smithy request - // then ensure that the URL is correct req := fm.request.Build(context.Background()) if e, a := test.url, req.URL.String(); e != a { t.Fatalf("expect url %s, got %s", e, a) diff --git a/service/s3/serializers.go b/service/s3/serializers.go index 0b14974aa98..9a2e10b79ba 100644 --- a/service/s3/serializers.go +++ b/service/s3/serializers.go @@ -52,6 +52,24 @@ func (m *awsRestxml_serializeOpAbortMultipartUpload) HandleSerialize(ctx context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "AbortMultipartUploadRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentAbortMultipartUploadInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -64,15 +82,6 @@ func awsRestxml_serializeOpHttpBindingsAbortMultipartUploadInput(v *AbortMultipa return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -99,6 +108,22 @@ func awsRestxml_serializeOpHttpBindingsAbortMultipartUploadInput(v *AbortMultipa return nil } +func awsRestxml_serializeOpDocumentAbortMultipartUploadInput(v *AbortMultipartUploadInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpCompleteMultipartUpload struct { } @@ -169,15 +194,6 @@ func awsRestxml_serializeOpHttpBindingsCompleteMultipartUploadInput(v *CompleteM return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ChecksumCRC32 != nil && len(*v.ChecksumCRC32) > 0 { locationName := "X-Amz-Checksum-Crc32" encoder.SetHeader(locationName).String(*v.ChecksumCRC32) @@ -273,6 +289,24 @@ func (m *awsRestxml_serializeOpCopyObject) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "CopyObjectRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentCopyObjectInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -290,15 +324,6 @@ func awsRestxml_serializeOpHttpBindingsCopyObjectInput(v *CopyObjectInput, encod encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BucketKeyEnabled { locationName := "X-Amz-Server-Side-Encryption-Bucket-Key-Enabled" encoder.SetHeader(locationName).Boolean(v.BucketKeyEnabled) @@ -505,6 +530,22 @@ func awsRestxml_serializeOpHttpBindingsCopyObjectInput(v *CopyObjectInput, encod return nil } +func awsRestxml_serializeOpDocumentCopyObjectInput(v *CopyObjectInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpCreateBucket struct { } @@ -580,15 +621,6 @@ func awsRestxml_serializeOpHttpBindingsCreateBucketInput(v *CreateBucketInput, e encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.GrantFullControl != nil && len(*v.GrantFullControl) > 0 { locationName := "X-Amz-Grant-Full-Control" encoder.SetHeader(locationName).String(*v.GrantFullControl) @@ -661,6 +693,24 @@ func (m *awsRestxml_serializeOpCreateMultipartUpload) HandleSerialize(ctx contex return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "CreateMultipartUploadRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentCreateMultipartUploadInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -678,15 +728,6 @@ func awsRestxml_serializeOpHttpBindingsCreateMultipartUploadInput(v *CreateMulti encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BucketKeyEnabled { locationName := "X-Amz-Server-Side-Encryption-Bucket-Key-Enabled" encoder.SetHeader(locationName).Boolean(v.BucketKeyEnabled) @@ -838,6 +879,22 @@ func awsRestxml_serializeOpHttpBindingsCreateMultipartUploadInput(v *CreateMulti return nil } +func awsRestxml_serializeOpDocumentCreateMultipartUploadInput(v *CreateMultipartUploadInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucket struct { } @@ -872,6 +929,24 @@ func (m *awsRestxml_serializeOpDeleteBucket) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -884,15 +959,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketInput(v *DeleteBucketInput, e return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -901,6 +967,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketInput(v *DeleteBucketInput, e return nil } +func awsRestxml_serializeOpDocumentDeleteBucketInput(v *DeleteBucketInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketAnalyticsConfiguration struct { } @@ -935,6 +1017,24 @@ func (m *awsRestxml_serializeOpDeleteBucketAnalyticsConfiguration) HandleSeriali return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketAnalyticsConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketAnalyticsConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -947,15 +1047,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketAnalyticsConfigurationInput(v return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -968,6 +1059,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketAnalyticsConfigurationInput(v return nil } +func awsRestxml_serializeOpDocumentDeleteBucketAnalyticsConfigurationInput(v *DeleteBucketAnalyticsConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketCors struct { } @@ -1002,6 +1109,24 @@ func (m *awsRestxml_serializeOpDeleteBucketCors) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketCorsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketCorsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1014,15 +1139,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketCorsInput(v *DeleteBucketCors return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1031,6 +1147,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketCorsInput(v *DeleteBucketCors return nil } +func awsRestxml_serializeOpDocumentDeleteBucketCorsInput(v *DeleteBucketCorsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketEncryption struct { } @@ -1065,6 +1197,24 @@ func (m *awsRestxml_serializeOpDeleteBucketEncryption) HandleSerialize(ctx conte return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketEncryptionRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketEncryptionInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1077,15 +1227,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketEncryptionInput(v *DeleteBuck return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1094,6 +1235,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketEncryptionInput(v *DeleteBuck return nil } +func awsRestxml_serializeOpDocumentDeleteBucketEncryptionInput(v *DeleteBucketEncryptionInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketIntelligentTieringConfiguration struct { } @@ -1128,6 +1285,24 @@ func (m *awsRestxml_serializeOpDeleteBucketIntelligentTieringConfiguration) Hand return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketIntelligentTieringConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketIntelligentTieringConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1140,15 +1315,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketIntelligentTieringConfigurati return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Id != nil { encoder.SetQuery("id").String(*v.Id) } @@ -1156,6 +1322,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketIntelligentTieringConfigurati return nil } +func awsRestxml_serializeOpDocumentDeleteBucketIntelligentTieringConfigurationInput(v *DeleteBucketIntelligentTieringConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketInventoryConfiguration struct { } @@ -1190,6 +1372,24 @@ func (m *awsRestxml_serializeOpDeleteBucketInventoryConfiguration) HandleSeriali return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketInventoryConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketInventoryConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1202,15 +1402,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketInventoryConfigurationInput(v return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1223,6 +1414,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketInventoryConfigurationInput(v return nil } +func awsRestxml_serializeOpDocumentDeleteBucketInventoryConfigurationInput(v *DeleteBucketInventoryConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketLifecycle struct { } @@ -1257,6 +1464,24 @@ func (m *awsRestxml_serializeOpDeleteBucketLifecycle) HandleSerialize(ctx contex return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketLifecycleRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketLifecycleInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1269,15 +1494,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketLifecycleInput(v *DeleteBucke return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1286,6 +1502,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketLifecycleInput(v *DeleteBucke return nil } +func awsRestxml_serializeOpDocumentDeleteBucketLifecycleInput(v *DeleteBucketLifecycleInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketMetricsConfiguration struct { } @@ -1320,6 +1552,24 @@ func (m *awsRestxml_serializeOpDeleteBucketMetricsConfiguration) HandleSerialize return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketMetricsConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketMetricsConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1332,15 +1582,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketMetricsConfigurationInput(v * return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1353,6 +1594,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketMetricsConfigurationInput(v * return nil } +func awsRestxml_serializeOpDocumentDeleteBucketMetricsConfigurationInput(v *DeleteBucketMetricsConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketOwnershipControls struct { } @@ -1387,6 +1644,24 @@ func (m *awsRestxml_serializeOpDeleteBucketOwnershipControls) HandleSerialize(ct return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketOwnershipControlsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketOwnershipControlsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1399,15 +1674,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketOwnershipControlsInput(v *Del return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1416,6 +1682,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketOwnershipControlsInput(v *Del return nil } +func awsRestxml_serializeOpDocumentDeleteBucketOwnershipControlsInput(v *DeleteBucketOwnershipControlsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketPolicy struct { } @@ -1450,6 +1732,24 @@ func (m *awsRestxml_serializeOpDeleteBucketPolicy) HandleSerialize(ctx context.C return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketPolicyRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketPolicyInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1462,15 +1762,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketPolicyInput(v *DeleteBucketPo return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1479,6 +1770,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketPolicyInput(v *DeleteBucketPo return nil } +func awsRestxml_serializeOpDocumentDeleteBucketPolicyInput(v *DeleteBucketPolicyInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketReplication struct { } @@ -1513,6 +1820,24 @@ func (m *awsRestxml_serializeOpDeleteBucketReplication) HandleSerialize(ctx cont return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketReplicationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketReplicationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1525,20 +1850,27 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketReplicationInput(v *DeleteBuc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} + if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { + locationName := "X-Amz-Expected-Bucket-Owner" + encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) } + + return nil +} + +func awsRestxml_serializeOpDocumentDeleteBucketReplicationInput(v *DeleteBucketReplicationInput, value smithyxml.Value) error { + defer value.Close() if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, } + el := value.MemberElement(root) + el.String(*v.Bucket) } - - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { - locationName := "X-Amz-Expected-Bucket-Owner" - encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) - } - return nil } @@ -1576,6 +1908,24 @@ func (m *awsRestxml_serializeOpDeleteBucketTagging) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketTaggingRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketTaggingInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1588,15 +1938,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketTaggingInput(v *DeleteBucketT return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1605,6 +1946,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketTaggingInput(v *DeleteBucketT return nil } +func awsRestxml_serializeOpDocumentDeleteBucketTaggingInput(v *DeleteBucketTaggingInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteBucketWebsite struct { } @@ -1639,6 +1996,24 @@ func (m *awsRestxml_serializeOpDeleteBucketWebsite) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteBucketWebsiteRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteBucketWebsiteInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1651,15 +2026,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketWebsiteInput(v *DeleteBucketW return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1668,6 +2034,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteBucketWebsiteInput(v *DeleteBucketW return nil } +func awsRestxml_serializeOpDocumentDeleteBucketWebsiteInput(v *DeleteBucketWebsiteInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteObject struct { } @@ -1702,6 +2084,24 @@ func (m *awsRestxml_serializeOpDeleteObject) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteObjectRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteObjectInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1714,15 +2114,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteObjectInput(v *DeleteObjectInput, e return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BypassGovernanceRetention { locationName := "X-Amz-Bypass-Governance-Retention" encoder.SetHeader(locationName).Boolean(v.BypassGovernanceRetention) @@ -1759,6 +2150,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteObjectInput(v *DeleteObjectInput, e return nil } +func awsRestxml_serializeOpDocumentDeleteObjectInput(v *DeleteObjectInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeleteObjects struct { } @@ -1829,15 +2236,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteObjectsInput(v *DeleteObjectsInput, return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BypassGovernanceRetention { locationName := "X-Amz-Bypass-Governance-Retention" encoder.SetHeader(locationName).Boolean(v.BypassGovernanceRetention) @@ -1900,6 +2298,24 @@ func (m *awsRestxml_serializeOpDeleteObjectTagging) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeleteObjectTaggingRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeleteObjectTaggingInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1912,15 +2328,6 @@ func awsRestxml_serializeOpHttpBindingsDeleteObjectTaggingInput(v *DeleteObjectT return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -1942,6 +2349,22 @@ func awsRestxml_serializeOpHttpBindingsDeleteObjectTaggingInput(v *DeleteObjectT return nil } +func awsRestxml_serializeOpDocumentDeleteObjectTaggingInput(v *DeleteObjectTaggingInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpDeletePublicAccessBlock struct { } @@ -1976,6 +2399,24 @@ func (m *awsRestxml_serializeOpDeletePublicAccessBlock) HandleSerialize(ctx cont return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "DeletePublicAccessBlockRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentDeletePublicAccessBlockInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1988,15 +2429,6 @@ func awsRestxml_serializeOpHttpBindingsDeletePublicAccessBlockInput(v *DeletePub return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2005,6 +2437,22 @@ func awsRestxml_serializeOpHttpBindingsDeletePublicAccessBlockInput(v *DeletePub return nil } +func awsRestxml_serializeOpDocumentDeletePublicAccessBlockInput(v *DeletePublicAccessBlockInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketAccelerateConfiguration struct { } @@ -2039,6 +2487,24 @@ func (m *awsRestxml_serializeOpGetBucketAccelerateConfiguration) HandleSerialize return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketAccelerateConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketAccelerateConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2051,15 +2517,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketAccelerateConfigurationInput(v * return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2073,6 +2530,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketAccelerateConfigurationInput(v * return nil } +func awsRestxml_serializeOpDocumentGetBucketAccelerateConfigurationInput(v *GetBucketAccelerateConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketAcl struct { } @@ -2107,25 +2580,34 @@ func (m *awsRestxml_serializeOpGetBucketAcl) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: err} } - if request.Request, err = restEncoder.Encode(request.Request); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} - } - in.Request = request + restEncoder.SetHeader("Content-Type").String("application/xml") - return next.HandleSerialize(ctx, in) -} -func awsRestxml_serializeOpHttpBindingsGetBucketAclInput(v *GetBucketAclInput, encoder *httpbinding.Encoder) error { - if v == nil { - return fmt.Errorf("unsupported serialization of nil %T", v) + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketAclRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketAclInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestxml_serializeOpHttpBindingsGetBucketAclInput(v *GetBucketAclInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) } if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { @@ -2136,6 +2618,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketAclInput(v *GetBucketAclInput, e return nil } +func awsRestxml_serializeOpDocumentGetBucketAclInput(v *GetBucketAclInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketAnalyticsConfiguration struct { } @@ -2170,6 +2668,24 @@ func (m *awsRestxml_serializeOpGetBucketAnalyticsConfiguration) HandleSerialize( return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketAnalyticsConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketAnalyticsConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2182,15 +2698,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketAnalyticsConfigurationInput(v *G return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2203,6 +2710,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketAnalyticsConfigurationInput(v *G return nil } +func awsRestxml_serializeOpDocumentGetBucketAnalyticsConfigurationInput(v *GetBucketAnalyticsConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketCors struct { } @@ -2237,6 +2760,24 @@ func (m *awsRestxml_serializeOpGetBucketCors) HandleSerialize(ctx context.Contex return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketCorsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketCorsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2249,15 +2790,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketCorsInput(v *GetBucketCorsInput, return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2266,6 +2798,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketCorsInput(v *GetBucketCorsInput, return nil } +func awsRestxml_serializeOpDocumentGetBucketCorsInput(v *GetBucketCorsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketEncryption struct { } @@ -2300,6 +2848,24 @@ func (m *awsRestxml_serializeOpGetBucketEncryption) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketEncryptionRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketEncryptionInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2312,15 +2878,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketEncryptionInput(v *GetBucketEncr return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2329,6 +2886,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketEncryptionInput(v *GetBucketEncr return nil } +func awsRestxml_serializeOpDocumentGetBucketEncryptionInput(v *GetBucketEncryptionInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketIntelligentTieringConfiguration struct { } @@ -2363,6 +2936,24 @@ func (m *awsRestxml_serializeOpGetBucketIntelligentTieringConfiguration) HandleS return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketIntelligentTieringConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketIntelligentTieringConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2375,15 +2966,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketIntelligentTieringConfigurationI return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Id != nil { encoder.SetQuery("id").String(*v.Id) } @@ -2391,6 +2973,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketIntelligentTieringConfigurationI return nil } +func awsRestxml_serializeOpDocumentGetBucketIntelligentTieringConfigurationInput(v *GetBucketIntelligentTieringConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketInventoryConfiguration struct { } @@ -2425,6 +3023,24 @@ func (m *awsRestxml_serializeOpGetBucketInventoryConfiguration) HandleSerialize( return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketInventoryConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketInventoryConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2437,15 +3053,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketInventoryConfigurationInput(v *G return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2458,6 +3065,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketInventoryConfigurationInput(v *G return nil } +func awsRestxml_serializeOpDocumentGetBucketInventoryConfigurationInput(v *GetBucketInventoryConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketLifecycleConfiguration struct { } @@ -2492,6 +3115,24 @@ func (m *awsRestxml_serializeOpGetBucketLifecycleConfiguration) HandleSerialize( return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketLifecycleConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketLifecycleConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2504,15 +3145,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLifecycleConfigurationInput(v *G return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2521,6 +3153,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLifecycleConfigurationInput(v *G return nil } +func awsRestxml_serializeOpDocumentGetBucketLifecycleConfigurationInput(v *GetBucketLifecycleConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketLocation struct { } @@ -2555,6 +3203,24 @@ func (m *awsRestxml_serializeOpGetBucketLocation) HandleSerialize(ctx context.Co return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketLocationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketLocationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2567,15 +3233,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLocationInput(v *GetBucketLocati return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2584,6 +3241,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLocationInput(v *GetBucketLocati return nil } +func awsRestxml_serializeOpDocumentGetBucketLocationInput(v *GetBucketLocationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketLogging struct { } @@ -2618,6 +3291,24 @@ func (m *awsRestxml_serializeOpGetBucketLogging) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketLoggingRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketLoggingInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2630,15 +3321,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLoggingInput(v *GetBucketLogging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2647,6 +3329,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketLoggingInput(v *GetBucketLogging return nil } +func awsRestxml_serializeOpDocumentGetBucketLoggingInput(v *GetBucketLoggingInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketMetricsConfiguration struct { } @@ -2681,6 +3379,24 @@ func (m *awsRestxml_serializeOpGetBucketMetricsConfiguration) HandleSerialize(ct return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketMetricsConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketMetricsConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2693,15 +3409,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketMetricsConfigurationInput(v *Get return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2714,6 +3421,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketMetricsConfigurationInput(v *Get return nil } +func awsRestxml_serializeOpDocumentGetBucketMetricsConfigurationInput(v *GetBucketMetricsConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketNotificationConfiguration struct { } @@ -2748,25 +3471,34 @@ func (m *awsRestxml_serializeOpGetBucketNotificationConfiguration) HandleSeriali return out, metadata, &smithy.SerializationError{Err: err} } - if request.Request, err = restEncoder.Encode(request.Request); err != nil { + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketNotificationConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketNotificationConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - in.Request = request - - return next.HandleSerialize(ctx, in) -} -func awsRestxml_serializeOpHttpBindingsGetBucketNotificationConfigurationInput(v *GetBucketNotificationConfigurationInput, encoder *httpbinding.Encoder) error { - if v == nil { - return fmt.Errorf("unsupported serialization of nil %T", v) + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestxml_serializeOpHttpBindingsGetBucketNotificationConfigurationInput(v *GetBucketNotificationConfigurationInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) } if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { @@ -2777,6 +3509,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketNotificationConfigurationInput(v return nil } +func awsRestxml_serializeOpDocumentGetBucketNotificationConfigurationInput(v *GetBucketNotificationConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketOwnershipControls struct { } @@ -2811,6 +3559,24 @@ func (m *awsRestxml_serializeOpGetBucketOwnershipControls) HandleSerialize(ctx c return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketOwnershipControlsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketOwnershipControlsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2823,15 +3589,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketOwnershipControlsInput(v *GetBuc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2840,6 +3597,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketOwnershipControlsInput(v *GetBuc return nil } +func awsRestxml_serializeOpDocumentGetBucketOwnershipControlsInput(v *GetBucketOwnershipControlsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketPolicy struct { } @@ -2874,6 +3647,24 @@ func (m *awsRestxml_serializeOpGetBucketPolicy) HandleSerialize(ctx context.Cont return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketPolicyRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketPolicyInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2886,15 +3677,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketPolicyInput(v *GetBucketPolicyIn return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2903,6 +3685,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketPolicyInput(v *GetBucketPolicyIn return nil } +func awsRestxml_serializeOpDocumentGetBucketPolicyInput(v *GetBucketPolicyInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketPolicyStatus struct { } @@ -2937,6 +3735,24 @@ func (m *awsRestxml_serializeOpGetBucketPolicyStatus) HandleSerialize(ctx contex return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketPolicyStatusRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketPolicyStatusInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -2949,15 +3765,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketPolicyStatusInput(v *GetBucketPo return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -2966,6 +3773,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketPolicyStatusInput(v *GetBucketPo return nil } +func awsRestxml_serializeOpDocumentGetBucketPolicyStatusInput(v *GetBucketPolicyStatusInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketReplication struct { } @@ -3000,6 +3823,24 @@ func (m *awsRestxml_serializeOpGetBucketReplication) HandleSerialize(ctx context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketReplicationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketReplicationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3012,15 +3853,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketReplicationInput(v *GetBucketRep return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3029,6 +3861,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketReplicationInput(v *GetBucketRep return nil } +func awsRestxml_serializeOpDocumentGetBucketReplicationInput(v *GetBucketReplicationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketRequestPayment struct { } @@ -3063,6 +3911,24 @@ func (m *awsRestxml_serializeOpGetBucketRequestPayment) HandleSerialize(ctx cont return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketRequestPaymentRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketRequestPaymentInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3075,15 +3941,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketRequestPaymentInput(v *GetBucket return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3092,6 +3949,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketRequestPaymentInput(v *GetBucket return nil } +func awsRestxml_serializeOpDocumentGetBucketRequestPaymentInput(v *GetBucketRequestPaymentInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketTagging struct { } @@ -3126,6 +3999,24 @@ func (m *awsRestxml_serializeOpGetBucketTagging) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketTaggingRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketTaggingInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3138,15 +4029,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketTaggingInput(v *GetBucketTagging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3155,6 +4037,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketTaggingInput(v *GetBucketTagging return nil } +func awsRestxml_serializeOpDocumentGetBucketTaggingInput(v *GetBucketTaggingInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketVersioning struct { } @@ -3189,6 +4087,24 @@ func (m *awsRestxml_serializeOpGetBucketVersioning) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketVersioningRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketVersioningInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3201,15 +4117,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketVersioningInput(v *GetBucketVers return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3218,6 +4125,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketVersioningInput(v *GetBucketVers return nil } +func awsRestxml_serializeOpDocumentGetBucketVersioningInput(v *GetBucketVersioningInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetBucketWebsite struct { } @@ -3252,6 +4175,24 @@ func (m *awsRestxml_serializeOpGetBucketWebsite) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetBucketWebsiteRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetBucketWebsiteInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3264,15 +4205,6 @@ func awsRestxml_serializeOpHttpBindingsGetBucketWebsiteInput(v *GetBucketWebsite return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3281,6 +4213,22 @@ func awsRestxml_serializeOpHttpBindingsGetBucketWebsiteInput(v *GetBucketWebsite return nil } +func awsRestxml_serializeOpDocumentGetBucketWebsiteInput(v *GetBucketWebsiteInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObject struct { } @@ -3315,6 +4263,24 @@ func (m *awsRestxml_serializeOpGetObject) HandleSerialize(ctx context.Context, i return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3327,15 +4293,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectInput(v *GetObjectInput, encoder return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumMode) > 0 { locationName := "X-Amz-Checksum-Mode" encoder.SetHeader(locationName).String(string(v.ChecksumMode)) @@ -3435,6 +4392,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectInput(v *GetObjectInput, encoder return nil } +func awsRestxml_serializeOpDocumentGetObjectInput(v *GetObjectInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectAcl struct { } @@ -3469,6 +4442,24 @@ func (m *awsRestxml_serializeOpGetObjectAcl) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectAclRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectAclInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3481,15 +4472,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectAclInput(v *GetObjectAclInput, e return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3516,6 +4498,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectAclInput(v *GetObjectAclInput, e return nil } +func awsRestxml_serializeOpDocumentGetObjectAclInput(v *GetObjectAclInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectAttributes struct { } @@ -3550,6 +4548,24 @@ func (m *awsRestxml_serializeOpGetObjectAttributes) HandleSerialize(ctx context. return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectAttributesRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectAttributesInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3562,15 +4578,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectAttributesInput(v *GetObjectAttr return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3636,6 +4643,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectAttributesInput(v *GetObjectAttr return nil } +func awsRestxml_serializeOpDocumentGetObjectAttributesInput(v *GetObjectAttributesInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectLegalHold struct { } @@ -3670,6 +4693,24 @@ func (m *awsRestxml_serializeOpGetObjectLegalHold) HandleSerialize(ctx context.C return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectLegalHoldRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectLegalHoldInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3682,15 +4723,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectLegalHoldInput(v *GetObjectLegal return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3717,6 +4749,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectLegalHoldInput(v *GetObjectLegal return nil } +func awsRestxml_serializeOpDocumentGetObjectLegalHoldInput(v *GetObjectLegalHoldInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectLockConfiguration struct { } @@ -3751,6 +4799,24 @@ func (m *awsRestxml_serializeOpGetObjectLockConfiguration) HandleSerialize(ctx c return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectLockConfigurationRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectLockConfigurationInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3763,15 +4829,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectLockConfigurationInput(v *GetObj return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3780,6 +4837,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectLockConfigurationInput(v *GetObj return nil } +func awsRestxml_serializeOpDocumentGetObjectLockConfigurationInput(v *GetObjectLockConfigurationInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectRetention struct { } @@ -3809,8 +4882,26 @@ func (m *awsRestxml_serializeOpGetObjectRetention) HandleSerialize(ctx context.C if err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - - if err := awsRestxml_serializeOpHttpBindingsGetObjectRetentionInput(input, restEncoder); err != nil { + + if err := awsRestxml_serializeOpHttpBindingsGetObjectRetentionInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectRetentionRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectRetentionInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3826,15 +4917,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectRetentionInput(v *GetObjectReten return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3861,6 +4943,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectRetentionInput(v *GetObjectReten return nil } +func awsRestxml_serializeOpDocumentGetObjectRetentionInput(v *GetObjectRetentionInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectTagging struct { } @@ -3895,6 +4993,24 @@ func (m *awsRestxml_serializeOpGetObjectTagging) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectTaggingRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectTaggingInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3907,15 +5023,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectTaggingInput(v *GetObjectTagging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -3942,6 +5049,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectTaggingInput(v *GetObjectTagging return nil } +func awsRestxml_serializeOpDocumentGetObjectTaggingInput(v *GetObjectTaggingInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetObjectTorrent struct { } @@ -3976,6 +5099,24 @@ func (m *awsRestxml_serializeOpGetObjectTorrent) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetObjectTorrentRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetObjectTorrentInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -3988,15 +5129,6 @@ func awsRestxml_serializeOpHttpBindingsGetObjectTorrentInput(v *GetObjectTorrent return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -4019,6 +5151,22 @@ func awsRestxml_serializeOpHttpBindingsGetObjectTorrentInput(v *GetObjectTorrent return nil } +func awsRestxml_serializeOpDocumentGetObjectTorrentInput(v *GetObjectTorrentInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpGetPublicAccessBlock struct { } @@ -4053,6 +5201,24 @@ func (m *awsRestxml_serializeOpGetPublicAccessBlock) HandleSerialize(ctx context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "GetPublicAccessBlockRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentGetPublicAccessBlockInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4065,15 +5231,6 @@ func awsRestxml_serializeOpHttpBindingsGetPublicAccessBlockInput(v *GetPublicAcc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -4082,6 +5239,22 @@ func awsRestxml_serializeOpHttpBindingsGetPublicAccessBlockInput(v *GetPublicAcc return nil } +func awsRestxml_serializeOpDocumentGetPublicAccessBlockInput(v *GetPublicAccessBlockInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpHeadBucket struct { } @@ -4116,6 +5289,24 @@ func (m *awsRestxml_serializeOpHeadBucket) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "HeadBucketRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentHeadBucketInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4128,15 +5319,6 @@ func awsRestxml_serializeOpHttpBindingsHeadBucketInput(v *HeadBucketInput, encod return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -4145,6 +5327,22 @@ func awsRestxml_serializeOpHttpBindingsHeadBucketInput(v *HeadBucketInput, encod return nil } +func awsRestxml_serializeOpDocumentHeadBucketInput(v *HeadBucketInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpHeadObject struct { } @@ -4179,6 +5377,24 @@ func (m *awsRestxml_serializeOpHeadObject) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "HeadObjectRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentHeadObjectInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4191,15 +5407,6 @@ func awsRestxml_serializeOpHttpBindingsHeadObjectInput(v *HeadObjectInput, encod return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumMode) > 0 { locationName := "X-Amz-Checksum-Mode" encoder.SetHeader(locationName).String(string(v.ChecksumMode)) @@ -4275,6 +5482,22 @@ func awsRestxml_serializeOpHttpBindingsHeadObjectInput(v *HeadObjectInput, encod return nil } +func awsRestxml_serializeOpDocumentHeadObjectInput(v *HeadObjectInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListBucketAnalyticsConfigurations struct { } @@ -4309,6 +5532,24 @@ func (m *awsRestxml_serializeOpListBucketAnalyticsConfigurations) HandleSerializ return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListBucketAnalyticsConfigurationsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListBucketAnalyticsConfigurationsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4321,15 +5562,6 @@ func awsRestxml_serializeOpHttpBindingsListBucketAnalyticsConfigurationsInput(v return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContinuationToken != nil { encoder.SetQuery("continuation-token").String(*v.ContinuationToken) } @@ -4342,6 +5574,22 @@ func awsRestxml_serializeOpHttpBindingsListBucketAnalyticsConfigurationsInput(v return nil } +func awsRestxml_serializeOpDocumentListBucketAnalyticsConfigurationsInput(v *ListBucketAnalyticsConfigurationsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListBucketIntelligentTieringConfigurations struct { } @@ -4372,7 +5620,25 @@ func (m *awsRestxml_serializeOpListBucketIntelligentTieringConfigurations) Handl return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestxml_serializeOpHttpBindingsListBucketIntelligentTieringConfigurationsInput(input, restEncoder); err != nil { + if err := awsRestxml_serializeOpHttpBindingsListBucketIntelligentTieringConfigurationsInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListBucketIntelligentTieringConfigurationsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListBucketIntelligentTieringConfigurationsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4388,15 +5654,6 @@ func awsRestxml_serializeOpHttpBindingsListBucketIntelligentTieringConfiguration return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContinuationToken != nil { encoder.SetQuery("continuation-token").String(*v.ContinuationToken) } @@ -4404,6 +5661,22 @@ func awsRestxml_serializeOpHttpBindingsListBucketIntelligentTieringConfiguration return nil } +func awsRestxml_serializeOpDocumentListBucketIntelligentTieringConfigurationsInput(v *ListBucketIntelligentTieringConfigurationsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListBucketInventoryConfigurations struct { } @@ -4438,6 +5711,24 @@ func (m *awsRestxml_serializeOpListBucketInventoryConfigurations) HandleSerializ return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListBucketInventoryConfigurationsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListBucketInventoryConfigurationsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4450,15 +5741,6 @@ func awsRestxml_serializeOpHttpBindingsListBucketInventoryConfigurationsInput(v return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContinuationToken != nil { encoder.SetQuery("continuation-token").String(*v.ContinuationToken) } @@ -4471,6 +5753,22 @@ func awsRestxml_serializeOpHttpBindingsListBucketInventoryConfigurationsInput(v return nil } +func awsRestxml_serializeOpDocumentListBucketInventoryConfigurationsInput(v *ListBucketInventoryConfigurationsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListBucketMetricsConfigurations struct { } @@ -4505,6 +5803,24 @@ func (m *awsRestxml_serializeOpListBucketMetricsConfigurations) HandleSerialize( return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListBucketMetricsConfigurationsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListBucketMetricsConfigurationsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4517,15 +5833,6 @@ func awsRestxml_serializeOpHttpBindingsListBucketMetricsConfigurationsInput(v *L return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContinuationToken != nil { encoder.SetQuery("continuation-token").String(*v.ContinuationToken) } @@ -4538,6 +5845,22 @@ func awsRestxml_serializeOpHttpBindingsListBucketMetricsConfigurationsInput(v *L return nil } +func awsRestxml_serializeOpDocumentListBucketMetricsConfigurationsInput(v *ListBucketMetricsConfigurationsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListBuckets struct { } @@ -4617,6 +5940,24 @@ func (m *awsRestxml_serializeOpListMultipartUploads) HandleSerialize(ctx context return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListMultipartUploadsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListMultipartUploadsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4629,15 +5970,6 @@ func awsRestxml_serializeOpHttpBindingsListMultipartUploadsInput(v *ListMultipar return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Delimiter != nil { encoder.SetQuery("delimiter").String(*v.Delimiter) } @@ -4675,6 +6007,22 @@ func awsRestxml_serializeOpHttpBindingsListMultipartUploadsInput(v *ListMultipar return nil } +func awsRestxml_serializeOpDocumentListMultipartUploadsInput(v *ListMultipartUploadsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListObjects struct { } @@ -4709,6 +6057,24 @@ func (m *awsRestxml_serializeOpListObjects) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListObjectsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListObjectsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4721,15 +6087,6 @@ func awsRestxml_serializeOpHttpBindingsListObjectsInput(v *ListObjectsInput, enc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Delimiter != nil { encoder.SetQuery("delimiter").String(*v.Delimiter) } @@ -4777,6 +6134,22 @@ func awsRestxml_serializeOpHttpBindingsListObjectsInput(v *ListObjectsInput, enc return nil } +func awsRestxml_serializeOpDocumentListObjectsInput(v *ListObjectsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListObjectsV2 struct { } @@ -4811,6 +6184,24 @@ func (m *awsRestxml_serializeOpListObjectsV2) HandleSerialize(ctx context.Contex return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListObjectsV2Request", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListObjectsV2Input(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4823,15 +6214,6 @@ func awsRestxml_serializeOpHttpBindingsListObjectsV2Input(v *ListObjectsV2Input, return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContinuationToken != nil { encoder.SetQuery("continuation-token").String(*v.ContinuationToken) } @@ -4887,6 +6269,22 @@ func awsRestxml_serializeOpHttpBindingsListObjectsV2Input(v *ListObjectsV2Input, return nil } +func awsRestxml_serializeOpDocumentListObjectsV2Input(v *ListObjectsV2Input, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpListObjectVersions struct { } @@ -4921,6 +6319,24 @@ func (m *awsRestxml_serializeOpListObjectVersions) HandleSerialize(ctx context.C return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListObjectVersionsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListObjectVersionsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -4933,15 +6349,6 @@ func awsRestxml_serializeOpHttpBindingsListObjectVersionsInput(v *ListObjectVers return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Delimiter != nil { encoder.SetQuery("delimiter").String(*v.Delimiter) } @@ -4989,7 +6396,23 @@ func awsRestxml_serializeOpHttpBindingsListObjectVersionsInput(v *ListObjectVers if v.VersionIdMarker != nil { encoder.SetQuery("version-id-marker").String(*v.VersionIdMarker) } - + + return nil +} + +func awsRestxml_serializeOpDocumentListObjectVersionsInput(v *ListObjectVersionsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } return nil } @@ -5027,6 +6450,24 @@ func (m *awsRestxml_serializeOpListParts) HandleSerialize(ctx context.Context, i return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "ListPartsRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentListPartsInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -5039,15 +6480,6 @@ func awsRestxml_serializeOpHttpBindingsListPartsInput(v *ListPartsInput, encoder return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -5097,6 +6529,22 @@ func awsRestxml_serializeOpHttpBindingsListPartsInput(v *ListPartsInput, encoder return nil } +func awsRestxml_serializeOpDocumentListPartsInput(v *ListPartsInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpPutBucketAccelerateConfiguration struct { } @@ -5167,15 +6615,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketAccelerateConfigurationInput(v * return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -5264,15 +6703,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketAclInput(v *PutBucketAclInput, e encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -5386,15 +6816,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketAnalyticsConfigurationInput(v *P return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -5477,15 +6898,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketCorsInput(v *PutBucketCorsInput, return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -5574,15 +6986,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketEncryptionInput(v *PutBucketEncr return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -5671,15 +7074,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketIntelligentTieringConfigurationI return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.Id != nil { encoder.SetQuery("id").String(*v.Id) } @@ -5757,15 +7151,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketInventoryConfigurationInput(v *P return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -5848,15 +7233,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketLifecycleConfigurationInput(v *P return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -5940,15 +7316,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketLoggingInput(v *PutBucketLogging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6037,15 +7404,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketMetricsConfigurationInput(v *Put return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -6128,15 +7486,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketNotificationConfigurationInput(v return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -6220,15 +7569,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketOwnershipControlsInput(v *PutBuc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ContentMD5 != nil && len(*v.ContentMD5) > 0 { locationName := "Content-Md5" encoder.SetHeader(locationName).String(*v.ContentMD5) @@ -6300,15 +7640,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketPolicyInput(v *PutBucketPolicyIn return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6402,15 +7733,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketReplicationInput(v *PutBucketRep return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6504,15 +7826,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketRequestPaymentInput(v *PutBucket return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6601,15 +7914,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketTaggingInput(v *PutBucketTagging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6698,15 +8002,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketVersioningInput(v *PutBucketVers return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6800,15 +8095,6 @@ func awsRestxml_serializeOpHttpBindingsPutBucketWebsiteInput(v *PutBucketWebsite return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -6890,15 +8176,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectInput(v *PutObjectInput, encoder encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BucketKeyEnabled { locationName := "X-Amz-Server-Side-Encryption-Bucket-Key-Enabled" encoder.SetHeader(locationName).Boolean(v.BucketKeyEnabled) @@ -7155,15 +8432,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectAclInput(v *PutObjectAclInput, e encoder.SetHeader(locationName).String(string(v.ACL)) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7295,15 +8563,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectLegalHoldInput(v *PutObjectLegal return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7410,15 +8669,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectLockConfigurationInput(v *PutObj return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7517,15 +8767,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectRetentionInput(v *PutObjectReten return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.BypassGovernanceRetention { locationName := "X-Amz-Bypass-Governance-Retention" encoder.SetHeader(locationName).Boolean(v.BypassGovernanceRetention) @@ -7637,15 +8878,6 @@ func awsRestxml_serializeOpHttpBindingsPutObjectTaggingInput(v *PutObjectTagging return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7752,15 +8984,6 @@ func awsRestxml_serializeOpHttpBindingsPutPublicAccessBlockInput(v *PutPublicAcc return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7849,15 +9072,6 @@ func awsRestxml_serializeOpHttpBindingsRestoreObjectInput(v *RestoreObjectInput, return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -7953,15 +9167,6 @@ func awsRestxml_serializeOpHttpBindingsSelectObjectContentInput(v *SelectObjectC return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.ExpectedBucketOwner != nil && len(*v.ExpectedBucketOwner) > 0 { locationName := "X-Amz-Expected-Bucket-Owner" encoder.SetHeader(locationName).String(*v.ExpectedBucketOwner) @@ -7996,6 +9201,17 @@ func awsRestxml_serializeOpHttpBindingsSelectObjectContentInput(v *SelectObjectC func awsRestxml_serializeOpDocumentSelectObjectContentInput(v *SelectObjectContentInput, value smithyxml.Value) error { defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } if v.Expression != nil { rootAttr := []smithyxml.Attr{} root := smithyxml.StartElement{ @@ -8131,15 +9347,6 @@ func awsRestxml_serializeOpHttpBindingsUploadPartInput(v *UploadPartInput, encod return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if len(v.ChecksumAlgorithm) > 0 { locationName := "X-Amz-Sdk-Checksum-Algorithm" encoder.SetHeader(locationName).String(string(v.ChecksumAlgorithm)) @@ -8254,6 +9461,24 @@ func (m *awsRestxml_serializeOpUploadPartCopy) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: err} } + restEncoder.SetHeader("Content-Type").String("application/xml") + + xmlEncoder := smithyxml.NewEncoder(bytes.NewBuffer(nil)) + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "UploadPartCopyRequest", + }, + Attr: rootAttr, + } + root.Attr = append(root.Attr, smithyxml.NewNamespaceAttribute("", "http://s3.amazonaws.com/doc/2006-03-01/")) + if err := awsRestxml_serializeOpDocumentUploadPartCopyInput(input, xmlEncoder.RootElement(root)); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request, err = request.SetStream(bytes.NewReader(xmlEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if request.Request, err = restEncoder.Encode(request.Request); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -8266,15 +9491,6 @@ func awsRestxml_serializeOpHttpBindingsUploadPartCopyInput(v *UploadPartCopyInpu return fmt.Errorf("unsupported serialization of nil %T", v) } - if v.Bucket == nil || len(*v.Bucket) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member Bucket must not be empty")} - } - if v.Bucket != nil { - if err := encoder.SetURI("Bucket").String(*v.Bucket); err != nil { - return err - } - } - if v.CopySource != nil && len(*v.CopySource) > 0 { locationName := "X-Amz-Copy-Source" encoder.SetHeader(locationName).String(*v.CopySource) @@ -8370,6 +9586,22 @@ func awsRestxml_serializeOpHttpBindingsUploadPartCopyInput(v *UploadPartCopyInpu return nil } +func awsRestxml_serializeOpDocumentUploadPartCopyInput(v *UploadPartCopyInput, value smithyxml.Value) error { + defer value.Close() + if v.Bucket != nil { + rootAttr := []smithyxml.Attr{} + root := smithyxml.StartElement{ + Name: smithyxml.Name{ + Local: "Bucket", + }, + Attr: rootAttr, + } + el := value.MemberElement(root) + el.String(*v.Bucket) + } + return nil +} + type awsRestxml_serializeOpWriteGetObjectResponse struct { } diff --git a/service/s3control/api_op_CreateAccessPoint.go b/service/s3control/api_op_CreateAccessPoint.go index 6696e611bcb..b4d5d0147ac 100644 --- a/service/s3control/api_op_CreateAccessPoint.go +++ b/service/s3control/api_op_CreateAccessPoint.go @@ -163,9 +163,6 @@ func (c *Client) addOperationCreateAccessPointMiddlewares(stack *middleware.Stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_CreateAccessPointForObjectLambda.go b/service/s3control/api_op_CreateAccessPointForObjectLambda.go index 1a4d246a7fe..b91d1667565 100644 --- a/service/s3control/api_op_CreateAccessPointForObjectLambda.go +++ b/service/s3control/api_op_CreateAccessPointForObjectLambda.go @@ -135,9 +135,6 @@ func (c *Client) addOperationCreateAccessPointForObjectLambdaMiddlewares(stack * if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateAccessPointForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_CreateBucket.go b/service/s3control/api_op_CreateBucket.go index e9bde165585..8ed2b85e4f2 100644 --- a/service/s3control/api_op_CreateBucket.go +++ b/service/s3control/api_op_CreateBucket.go @@ -185,9 +185,6 @@ func (c *Client) addOperationCreateBucketMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_CreateJob.go b/service/s3control/api_op_CreateJob.go index 82e7c6df59b..c6b919025e9 100644 --- a/service/s3control/api_op_CreateJob.go +++ b/service/s3control/api_op_CreateJob.go @@ -177,9 +177,6 @@ func (c *Client) addOperationCreateJobMiddlewares(stack *middleware.Stack, optio if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateJobUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_CreateMultiRegionAccessPoint.go b/service/s3control/api_op_CreateMultiRegionAccessPoint.go index 826197990f9..c09635fb0e5 100644 --- a/service/s3control/api_op_CreateMultiRegionAccessPoint.go +++ b/service/s3control/api_op_CreateMultiRegionAccessPoint.go @@ -150,9 +150,6 @@ func (c *Client) addOperationCreateMultiRegionAccessPointMiddlewares(stack *midd if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addCreateMultiRegionAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteAccessPoint.go b/service/s3control/api_op_DeleteAccessPoint.go index 869c117016d..215f85c276f 100644 --- a/service/s3control/api_op_DeleteAccessPoint.go +++ b/service/s3control/api_op_DeleteAccessPoint.go @@ -133,9 +133,6 @@ func (c *Client) addOperationDeleteAccessPointMiddlewares(stack *middleware.Stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteAccessPointForObjectLambda.go b/service/s3control/api_op_DeleteAccessPointForObjectLambda.go index 3e7da890bd0..cec23e71222 100644 --- a/service/s3control/api_op_DeleteAccessPointForObjectLambda.go +++ b/service/s3control/api_op_DeleteAccessPointForObjectLambda.go @@ -120,9 +120,6 @@ func (c *Client) addOperationDeleteAccessPointForObjectLambdaMiddlewares(stack * if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteAccessPointForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteAccessPointPolicy.go b/service/s3control/api_op_DeleteAccessPointPolicy.go index 67432f9078f..0c120253501 100644 --- a/service/s3control/api_op_DeleteAccessPointPolicy.go +++ b/service/s3control/api_op_DeleteAccessPointPolicy.go @@ -133,9 +133,6 @@ func (c *Client) addOperationDeleteAccessPointPolicyMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteAccessPointPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteAccessPointPolicyForObjectLambda.go b/service/s3control/api_op_DeleteAccessPointPolicyForObjectLambda.go index ea76d239d40..f84bfd1f581 100644 --- a/service/s3control/api_op_DeleteAccessPointPolicyForObjectLambda.go +++ b/service/s3control/api_op_DeleteAccessPointPolicyForObjectLambda.go @@ -119,9 +119,6 @@ func (c *Client) addOperationDeleteAccessPointPolicyForObjectLambdaMiddlewares(s if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteAccessPointPolicyForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteBucket.go b/service/s3control/api_op_DeleteBucket.go index 31e5665f1ed..516b8ae505d 100644 --- a/service/s3control/api_op_DeleteBucket.go +++ b/service/s3control/api_op_DeleteBucket.go @@ -138,9 +138,6 @@ func (c *Client) addOperationDeleteBucketMiddlewares(stack *middleware.Stack, op if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteBucketLifecycleConfiguration.go b/service/s3control/api_op_DeleteBucketLifecycleConfiguration.go index a0a8bb4b7af..0dee6ada8c7 100644 --- a/service/s3control/api_op_DeleteBucketLifecycleConfiguration.go +++ b/service/s3control/api_op_DeleteBucketLifecycleConfiguration.go @@ -144,9 +144,6 @@ func (c *Client) addOperationDeleteBucketLifecycleConfigurationMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketLifecycleConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteBucketPolicy.go b/service/s3control/api_op_DeleteBucketPolicy.go index 19ff5c95454..2e13e816012 100644 --- a/service/s3control/api_op_DeleteBucketPolicy.go +++ b/service/s3control/api_op_DeleteBucketPolicy.go @@ -148,9 +148,6 @@ func (c *Client) addOperationDeleteBucketPolicyMiddlewares(stack *middleware.Sta if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteBucketReplication.go b/service/s3control/api_op_DeleteBucketReplication.go index 1ea959911f1..76a4129d6c0 100644 --- a/service/s3control/api_op_DeleteBucketReplication.go +++ b/service/s3control/api_op_DeleteBucketReplication.go @@ -151,9 +151,6 @@ func (c *Client) addOperationDeleteBucketReplicationMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteBucketTagging.go b/service/s3control/api_op_DeleteBucketTagging.go index 7f5f9affb4a..9f749d9b905 100644 --- a/service/s3control/api_op_DeleteBucketTagging.go +++ b/service/s3control/api_op_DeleteBucketTagging.go @@ -137,9 +137,6 @@ func (c *Client) addOperationDeleteBucketTaggingMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteJobTagging.go b/service/s3control/api_op_DeleteJobTagging.go index 3b562094527..18d481e4f81 100644 --- a/service/s3control/api_op_DeleteJobTagging.go +++ b/service/s3control/api_op_DeleteJobTagging.go @@ -122,9 +122,6 @@ func (c *Client) addOperationDeleteJobTaggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteJobTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteMultiRegionAccessPoint.go b/service/s3control/api_op_DeleteMultiRegionAccessPoint.go index 2477d47b0d1..cd520abcaa1 100644 --- a/service/s3control/api_op_DeleteMultiRegionAccessPoint.go +++ b/service/s3control/api_op_DeleteMultiRegionAccessPoint.go @@ -148,9 +148,6 @@ func (c *Client) addOperationDeleteMultiRegionAccessPointMiddlewares(stack *midd if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteMultiRegionAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeletePublicAccessBlock.go b/service/s3control/api_op_DeletePublicAccessBlock.go index 97f954896f9..09b22743a49 100644 --- a/service/s3control/api_op_DeletePublicAccessBlock.go +++ b/service/s3control/api_op_DeletePublicAccessBlock.go @@ -115,9 +115,6 @@ func (c *Client) addOperationDeletePublicAccessBlockMiddlewares(stack *middlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeletePublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteStorageLensConfiguration.go b/service/s3control/api_op_DeleteStorageLensConfiguration.go index 31edbfef7c7..d5111d846cf 100644 --- a/service/s3control/api_op_DeleteStorageLensConfiguration.go +++ b/service/s3control/api_op_DeleteStorageLensConfiguration.go @@ -121,9 +121,6 @@ func (c *Client) addOperationDeleteStorageLensConfigurationMiddlewares(stack *mi if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteStorageLensConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DeleteStorageLensConfigurationTagging.go b/service/s3control/api_op_DeleteStorageLensConfigurationTagging.go index e4935f174ae..631ef65c2ae 100644 --- a/service/s3control/api_op_DeleteStorageLensConfigurationTagging.go +++ b/service/s3control/api_op_DeleteStorageLensConfigurationTagging.go @@ -121,9 +121,6 @@ func (c *Client) addOperationDeleteStorageLensConfigurationTaggingMiddlewares(st if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDeleteStorageLensConfigurationTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DescribeJob.go b/service/s3control/api_op_DescribeJob.go index 8381563ea23..05b8eb21109 100644 --- a/service/s3control/api_op_DescribeJob.go +++ b/service/s3control/api_op_DescribeJob.go @@ -127,9 +127,6 @@ func (c *Client) addOperationDescribeJobMiddlewares(stack *middleware.Stack, opt if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDescribeJobUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_DescribeMultiRegionAccessPointOperation.go b/service/s3control/api_op_DescribeMultiRegionAccessPointOperation.go index f0a2828f323..977af7f146a 100644 --- a/service/s3control/api_op_DescribeMultiRegionAccessPointOperation.go +++ b/service/s3control/api_op_DescribeMultiRegionAccessPointOperation.go @@ -135,9 +135,6 @@ func (c *Client) addOperationDescribeMultiRegionAccessPointOperationMiddlewares( if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addDescribeMultiRegionAccessPointOperationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPoint.go b/service/s3control/api_op_GetAccessPoint.go index e536e3aaa0e..0a460176c48 100644 --- a/service/s3control/api_op_GetAccessPoint.go +++ b/service/s3control/api_op_GetAccessPoint.go @@ -181,9 +181,6 @@ func (c *Client) addOperationGetAccessPointMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointConfigurationForObjectLambda.go b/service/s3control/api_op_GetAccessPointConfigurationForObjectLambda.go index cd29fbb711c..58b3fac183a 100644 --- a/service/s3control/api_op_GetAccessPointConfigurationForObjectLambda.go +++ b/service/s3control/api_op_GetAccessPointConfigurationForObjectLambda.go @@ -124,9 +124,6 @@ func (c *Client) addOperationGetAccessPointConfigurationForObjectLambdaMiddlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointConfigurationForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointForObjectLambda.go b/service/s3control/api_op_GetAccessPointForObjectLambda.go index 5b5fdcb2aea..e55b6831ba8 100644 --- a/service/s3control/api_op_GetAccessPointForObjectLambda.go +++ b/service/s3control/api_op_GetAccessPointForObjectLambda.go @@ -136,9 +136,6 @@ func (c *Client) addOperationGetAccessPointForObjectLambdaMiddlewares(stack *mid if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointPolicy.go b/service/s3control/api_op_GetAccessPointPolicy.go index 3ea98f642ff..7c774c2fd0a 100644 --- a/service/s3control/api_op_GetAccessPointPolicy.go +++ b/service/s3control/api_op_GetAccessPointPolicy.go @@ -131,9 +131,6 @@ func (c *Client) addOperationGetAccessPointPolicyMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointPolicyForObjectLambda.go b/service/s3control/api_op_GetAccessPointPolicyForObjectLambda.go index 3194fa9cdb7..83adbf07934 100644 --- a/service/s3control/api_op_GetAccessPointPolicyForObjectLambda.go +++ b/service/s3control/api_op_GetAccessPointPolicyForObjectLambda.go @@ -123,9 +123,6 @@ func (c *Client) addOperationGetAccessPointPolicyForObjectLambdaMiddlewares(stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointPolicyForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointPolicyStatus.go b/service/s3control/api_op_GetAccessPointPolicyStatus.go index f2bd613c015..8912c898938 100644 --- a/service/s3control/api_op_GetAccessPointPolicyStatus.go +++ b/service/s3control/api_op_GetAccessPointPolicyStatus.go @@ -123,9 +123,6 @@ func (c *Client) addOperationGetAccessPointPolicyStatusMiddlewares(stack *middle if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointPolicyStatusUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetAccessPointPolicyStatusForObjectLambda.go b/service/s3control/api_op_GetAccessPointPolicyStatusForObjectLambda.go index b89f237f953..12cd7788ae1 100644 --- a/service/s3control/api_op_GetAccessPointPolicyStatusForObjectLambda.go +++ b/service/s3control/api_op_GetAccessPointPolicyStatusForObjectLambda.go @@ -125,9 +125,6 @@ func (c *Client) addOperationGetAccessPointPolicyStatusForObjectLambdaMiddleware if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetAccessPointPolicyStatusForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucket.go b/service/s3control/api_op_GetBucket.go index 7edbbe809a6..aa4f00b8eb1 100644 --- a/service/s3control/api_op_GetBucket.go +++ b/service/s3control/api_op_GetBucket.go @@ -154,9 +154,6 @@ func (c *Client) addOperationGetBucketMiddlewares(stack *middleware.Stack, optio if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucketLifecycleConfiguration.go b/service/s3control/api_op_GetBucketLifecycleConfiguration.go index 7dab63c1a6e..a58a16df5c5 100644 --- a/service/s3control/api_op_GetBucketLifecycleConfiguration.go +++ b/service/s3control/api_op_GetBucketLifecycleConfiguration.go @@ -155,9 +155,6 @@ func (c *Client) addOperationGetBucketLifecycleConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketLifecycleConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucketPolicy.go b/service/s3control/api_op_GetBucketPolicy.go index bae9f1ee815..780817aeff8 100644 --- a/service/s3control/api_op_GetBucketPolicy.go +++ b/service/s3control/api_op_GetBucketPolicy.go @@ -152,9 +152,6 @@ func (c *Client) addOperationGetBucketPolicyMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucketReplication.go b/service/s3control/api_op_GetBucketReplication.go index b530cb9975e..f66eea1651e 100644 --- a/service/s3control/api_op_GetBucketReplication.go +++ b/service/s3control/api_op_GetBucketReplication.go @@ -161,9 +161,6 @@ func (c *Client) addOperationGetBucketReplicationMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucketTagging.go b/service/s3control/api_op_GetBucketTagging.go index a964bd213ae..4536fb8bac6 100644 --- a/service/s3control/api_op_GetBucketTagging.go +++ b/service/s3control/api_op_GetBucketTagging.go @@ -149,9 +149,6 @@ func (c *Client) addOperationGetBucketTaggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetBucketVersioning.go b/service/s3control/api_op_GetBucketVersioning.go index 16535409590..663ed9ce2a9 100644 --- a/service/s3control/api_op_GetBucketVersioning.go +++ b/service/s3control/api_op_GetBucketVersioning.go @@ -144,9 +144,6 @@ func (c *Client) addOperationGetBucketVersioningMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetBucketVersioningUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetJobTagging.go b/service/s3control/api_op_GetJobTagging.go index 66f8dec03fe..04112bb3cad 100644 --- a/service/s3control/api_op_GetJobTagging.go +++ b/service/s3control/api_op_GetJobTagging.go @@ -126,9 +126,6 @@ func (c *Client) addOperationGetJobTaggingMiddlewares(stack *middleware.Stack, o if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetJobTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetMultiRegionAccessPoint.go b/service/s3control/api_op_GetMultiRegionAccessPoint.go index 9ba006a297b..a7877a7c8fa 100644 --- a/service/s3control/api_op_GetMultiRegionAccessPoint.go +++ b/service/s3control/api_op_GetMultiRegionAccessPoint.go @@ -138,9 +138,6 @@ func (c *Client) addOperationGetMultiRegionAccessPointMiddlewares(stack *middlew if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetMultiRegionAccessPointUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetMultiRegionAccessPointPolicy.go b/service/s3control/api_op_GetMultiRegionAccessPointPolicy.go index 79b91d2a07d..b51beb55138 100644 --- a/service/s3control/api_op_GetMultiRegionAccessPointPolicy.go +++ b/service/s3control/api_op_GetMultiRegionAccessPointPolicy.go @@ -135,9 +135,6 @@ func (c *Client) addOperationGetMultiRegionAccessPointPolicyMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetMultiRegionAccessPointPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetMultiRegionAccessPointPolicyStatus.go b/service/s3control/api_op_GetMultiRegionAccessPointPolicyStatus.go index 8c0607cca57..e3020b38a15 100644 --- a/service/s3control/api_op_GetMultiRegionAccessPointPolicyStatus.go +++ b/service/s3control/api_op_GetMultiRegionAccessPointPolicyStatus.go @@ -138,9 +138,6 @@ func (c *Client) addOperationGetMultiRegionAccessPointPolicyStatusMiddlewares(st if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetMultiRegionAccessPointPolicyStatusUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetMultiRegionAccessPointRoutes.go b/service/s3control/api_op_GetMultiRegionAccessPointRoutes.go index bbdc43bc15e..b4cf88939ed 100644 --- a/service/s3control/api_op_GetMultiRegionAccessPointRoutes.go +++ b/service/s3control/api_op_GetMultiRegionAccessPointRoutes.go @@ -138,9 +138,6 @@ func (c *Client) addOperationGetMultiRegionAccessPointRoutesMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetMultiRegionAccessPointRoutesUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetPublicAccessBlock.go b/service/s3control/api_op_GetPublicAccessBlock.go index 06660f7be58..3e49af18b8f 100644 --- a/service/s3control/api_op_GetPublicAccessBlock.go +++ b/service/s3control/api_op_GetPublicAccessBlock.go @@ -121,9 +121,6 @@ func (c *Client) addOperationGetPublicAccessBlockMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetPublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetStorageLensConfiguration.go b/service/s3control/api_op_GetStorageLensConfiguration.go index 3ce64b8a422..04de59a11cc 100644 --- a/service/s3control/api_op_GetStorageLensConfiguration.go +++ b/service/s3control/api_op_GetStorageLensConfiguration.go @@ -127,9 +127,6 @@ func (c *Client) addOperationGetStorageLensConfigurationMiddlewares(stack *middl if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetStorageLensConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_GetStorageLensConfigurationTagging.go b/service/s3control/api_op_GetStorageLensConfigurationTagging.go index 52371d283f5..6421fa67ec2 100644 --- a/service/s3control/api_op_GetStorageLensConfigurationTagging.go +++ b/service/s3control/api_op_GetStorageLensConfigurationTagging.go @@ -126,9 +126,6 @@ func (c *Client) addOperationGetStorageLensConfigurationTaggingMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addGetStorageLensConfigurationTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListAccessPoints.go b/service/s3control/api_op_ListAccessPoints.go index b91cb9b2c59..c435decf549 100644 --- a/service/s3control/api_op_ListAccessPoints.go +++ b/service/s3control/api_op_ListAccessPoints.go @@ -158,9 +158,6 @@ func (c *Client) addOperationListAccessPointsMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListAccessPointsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListAccessPointsForObjectLambda.go b/service/s3control/api_op_ListAccessPointsForObjectLambda.go index ec4d2eb9ca1..0fbb090f6ba 100644 --- a/service/s3control/api_op_ListAccessPointsForObjectLambda.go +++ b/service/s3control/api_op_ListAccessPointsForObjectLambda.go @@ -140,9 +140,6 @@ func (c *Client) addOperationListAccessPointsForObjectLambdaMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListAccessPointsForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListJobs.go b/service/s3control/api_op_ListJobs.go index d69dc17578c..1b842f5c891 100644 --- a/service/s3control/api_op_ListJobs.go +++ b/service/s3control/api_op_ListJobs.go @@ -142,9 +142,6 @@ func (c *Client) addOperationListJobsMiddlewares(stack *middleware.Stack, option if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListJobsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListMultiRegionAccessPoints.go b/service/s3control/api_op_ListMultiRegionAccessPoints.go index f6b49ec5617..b7bf57066fa 100644 --- a/service/s3control/api_op_ListMultiRegionAccessPoints.go +++ b/service/s3control/api_op_ListMultiRegionAccessPoints.go @@ -143,9 +143,6 @@ func (c *Client) addOperationListMultiRegionAccessPointsMiddlewares(stack *middl if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListMultiRegionAccessPointsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListRegionalBuckets.go b/service/s3control/api_op_ListRegionalBuckets.go index 961790d5f4b..54dc3f152f9 100644 --- a/service/s3control/api_op_ListRegionalBuckets.go +++ b/service/s3control/api_op_ListRegionalBuckets.go @@ -136,9 +136,6 @@ func (c *Client) addOperationListRegionalBucketsMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListRegionalBucketsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_ListStorageLensConfigurations.go b/service/s3control/api_op_ListStorageLensConfigurations.go index 0b2c00d6f60..18feb053de6 100644 --- a/service/s3control/api_op_ListStorageLensConfigurations.go +++ b/service/s3control/api_op_ListStorageLensConfigurations.go @@ -129,9 +129,6 @@ func (c *Client) addOperationListStorageLensConfigurationsMiddlewares(stack *mid if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addListStorageLensConfigurationsUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutAccessPointConfigurationForObjectLambda.go b/service/s3control/api_op_PutAccessPointConfigurationForObjectLambda.go index df4237c15b6..bc732811220 100644 --- a/service/s3control/api_op_PutAccessPointConfigurationForObjectLambda.go +++ b/service/s3control/api_op_PutAccessPointConfigurationForObjectLambda.go @@ -124,9 +124,6 @@ func (c *Client) addOperationPutAccessPointConfigurationForObjectLambdaMiddlewar if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutAccessPointConfigurationForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutAccessPointPolicy.go b/service/s3control/api_op_PutAccessPointPolicy.go index 4c432b15100..8a4bfd39907 100644 --- a/service/s3control/api_op_PutAccessPointPolicy.go +++ b/service/s3control/api_op_PutAccessPointPolicy.go @@ -144,9 +144,6 @@ func (c *Client) addOperationPutAccessPointPolicyMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutAccessPointPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutAccessPointPolicyForObjectLambda.go b/service/s3control/api_op_PutAccessPointPolicyForObjectLambda.go index 25d04014cf7..36eadbcbebe 100644 --- a/service/s3control/api_op_PutAccessPointPolicyForObjectLambda.go +++ b/service/s3control/api_op_PutAccessPointPolicyForObjectLambda.go @@ -126,9 +126,6 @@ func (c *Client) addOperationPutAccessPointPolicyForObjectLambdaMiddlewares(stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutAccessPointPolicyForObjectLambdaUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutBucketLifecycleConfiguration.go b/service/s3control/api_op_PutBucketLifecycleConfiguration.go index 140bdb26c2b..fa69869775e 100644 --- a/service/s3control/api_op_PutBucketLifecycleConfiguration.go +++ b/service/s3control/api_op_PutBucketLifecycleConfiguration.go @@ -137,9 +137,6 @@ func (c *Client) addOperationPutBucketLifecycleConfigurationMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketLifecycleConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutBucketPolicy.go b/service/s3control/api_op_PutBucketPolicy.go index c97a29a7298..afc81745c0c 100644 --- a/service/s3control/api_op_PutBucketPolicy.go +++ b/service/s3control/api_op_PutBucketPolicy.go @@ -160,9 +160,6 @@ func (c *Client) addOperationPutBucketPolicyMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutBucketReplication.go b/service/s3control/api_op_PutBucketReplication.go index 612bf2c0cf5..2ecb2d58c01 100644 --- a/service/s3control/api_op_PutBucketReplication.go +++ b/service/s3control/api_op_PutBucketReplication.go @@ -187,9 +187,6 @@ func (c *Client) addOperationPutBucketReplicationMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketReplicationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutBucketTagging.go b/service/s3control/api_op_PutBucketTagging.go index 18a9ab26303..396584cb44b 100644 --- a/service/s3control/api_op_PutBucketTagging.go +++ b/service/s3control/api_op_PutBucketTagging.go @@ -177,9 +177,6 @@ func (c *Client) addOperationPutBucketTaggingMiddlewares(stack *middleware.Stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutBucketVersioning.go b/service/s3control/api_op_PutBucketVersioning.go index dbf43d97b54..f6952fa5efe 100644 --- a/service/s3control/api_op_PutBucketVersioning.go +++ b/service/s3control/api_op_PutBucketVersioning.go @@ -162,9 +162,6 @@ func (c *Client) addOperationPutBucketVersioningMiddlewares(stack *middleware.St if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutBucketVersioningUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutJobTagging.go b/service/s3control/api_op_PutJobTagging.go index ac47f8814b0..331fec4b7cb 100644 --- a/service/s3control/api_op_PutJobTagging.go +++ b/service/s3control/api_op_PutJobTagging.go @@ -153,9 +153,6 @@ func (c *Client) addOperationPutJobTaggingMiddlewares(stack *middleware.Stack, o if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutJobTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutMultiRegionAccessPointPolicy.go b/service/s3control/api_op_PutMultiRegionAccessPointPolicy.go index 05dd4811f7f..46cf8355b31 100644 --- a/service/s3control/api_op_PutMultiRegionAccessPointPolicy.go +++ b/service/s3control/api_op_PutMultiRegionAccessPointPolicy.go @@ -145,9 +145,6 @@ func (c *Client) addOperationPutMultiRegionAccessPointPolicyMiddlewares(stack *m if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutMultiRegionAccessPointPolicyUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutPublicAccessBlock.go b/service/s3control/api_op_PutPublicAccessBlock.go index 5e63daa9d28..d2a433980d1 100644 --- a/service/s3control/api_op_PutPublicAccessBlock.go +++ b/service/s3control/api_op_PutPublicAccessBlock.go @@ -124,9 +124,6 @@ func (c *Client) addOperationPutPublicAccessBlockMiddlewares(stack *middleware.S if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutPublicAccessBlockUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutStorageLensConfiguration.go b/service/s3control/api_op_PutStorageLensConfiguration.go index 99d13210c58..735e8e667ac 100644 --- a/service/s3control/api_op_PutStorageLensConfiguration.go +++ b/service/s3control/api_op_PutStorageLensConfiguration.go @@ -132,9 +132,6 @@ func (c *Client) addOperationPutStorageLensConfigurationMiddlewares(stack *middl if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutStorageLensConfigurationUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_PutStorageLensConfigurationTagging.go b/service/s3control/api_op_PutStorageLensConfigurationTagging.go index 701674c1742..2ce8baa35ac 100644 --- a/service/s3control/api_op_PutStorageLensConfigurationTagging.go +++ b/service/s3control/api_op_PutStorageLensConfigurationTagging.go @@ -128,9 +128,6 @@ func (c *Client) addOperationPutStorageLensConfigurationTaggingMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addPutStorageLensConfigurationTaggingUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_SubmitMultiRegionAccessPointRoutes.go b/service/s3control/api_op_SubmitMultiRegionAccessPointRoutes.go index 249094990ce..02004550744 100644 --- a/service/s3control/api_op_SubmitMultiRegionAccessPointRoutes.go +++ b/service/s3control/api_op_SubmitMultiRegionAccessPointRoutes.go @@ -146,9 +146,6 @@ func (c *Client) addOperationSubmitMultiRegionAccessPointRoutesMiddlewares(stack if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addSubmitMultiRegionAccessPointRoutesUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_UpdateJobPriority.go b/service/s3control/api_op_UpdateJobPriority.go index 9cff2a515e4..d85e67db2d7 100644 --- a/service/s3control/api_op_UpdateJobPriority.go +++ b/service/s3control/api_op_UpdateJobPriority.go @@ -137,9 +137,6 @@ func (c *Client) addOperationUpdateJobPriorityMiddlewares(stack *middleware.Stac if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addUpdateJobPriorityUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3control/api_op_UpdateJobStatus.go b/service/s3control/api_op_UpdateJobStatus.go index 3638b76c306..3ef67ab911d 100644 --- a/service/s3control/api_op_UpdateJobStatus.go +++ b/service/s3control/api_op_UpdateJobStatus.go @@ -142,9 +142,6 @@ func (c *Client) addOperationUpdateJobStatusMiddlewares(stack *middleware.Stack, if err = awsmiddleware.AddRecursionDetection(stack); err != nil { return err } - if err = addUpdateJobStatusUpdateEndpoint(stack, options); err != nil { - return err - } if err = addResponseErrorMiddleware(stack); err != nil { return err } diff --git a/service/s3outposts/go.mod b/service/s3outposts/go.mod index c89979d587d..c1e54abe814 100644 --- a/service/s3outposts/go.mod +++ b/service/s3outposts/go.mod @@ -14,5 +14,4 @@ require ( github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.0.0-00010101000000-000000000000 github.com/aws/smithy-go v1.4.0 github.com/google/go-cmp v0.5.4 - github.com/aws/aws-sdk-go-v2 v1.4.0 )