From ad521060000fcf57abf457d6d9be1cc0290c0a4f Mon Sep 17 00:00:00 2001 From: AWS SDK for Go v2 automation user Date: Thu, 27 Jul 2023 18:43:46 +0000 Subject: [PATCH] Regenerated Clients --- .../18daa891967d40b28ab7d73705b451a2.json | 8 + .../725d40a1698045a3b0853d96c615158a.json | 8 + .../814f0818c064439088ef873f775fdde3.json | 8 + .../8a37aa67d7244b1a849e1d3c4f040ae4.json | 8 + .../f8600d688a904cc1828df6985b3324be.json | 8 + .../api_op_CompleteLifecycleAction.go | 2 +- .../autoscaling/api_op_DescribeWarmPool.go | 92 +++++++ .../api_op_DetachTrafficSources.go | 8 +- .../autoscaling/api_op_PutScalingPolicy.go | 2 +- .../api_op_RollbackInstanceRefresh.go | 5 + service/autoscaling/types/types.go | 5 +- service/autoscaling/validators.go | 39 +++ service/ebs/api_op_CompleteSnapshot.go | 6 +- service/ebs/api_op_GetSnapshotBlock.go | 6 +- service/ebs/api_op_ListChangedBlocks.go | 6 +- service/ebs/api_op_ListSnapshotBlocks.go | 4 + service/ebs/api_op_PutSnapshotBlock.go | 6 +- service/ebs/api_op_StartSnapshot.go | 9 +- service/ebs/deserializers.go | 9 + service/ebs/types/enums.go | 30 +++ service/ebs/types/errors.go | 8 +- service/ec2/api_op_CreateSnapshot.go | 3 + service/ec2/api_op_CreateVolume.go | 3 + service/ec2/api_op_DescribeStoreImageTasks.go | 229 ++++++++++++++++++ .../ec2/api_op_GetEbsEncryptionByDefault.go | 4 + .../api_op_RestoreSnapshotFromRecycleBin.go | 3 + service/ec2/deserializers.go | 91 +++++++ service/ec2/types/enums.go | 20 ++ service/ec2/types/types.go | 9 + service/eks/types/enums.go | 68 ++++-- service/sagemaker/deserializers.go | 5 + service/sagemaker/types/types.go | 4 + 32 files changed, 678 insertions(+), 38 deletions(-) create mode 100644 .changelog/18daa891967d40b28ab7d73705b451a2.json create mode 100644 .changelog/725d40a1698045a3b0853d96c615158a.json create mode 100644 .changelog/814f0818c064439088ef873f775fdde3.json create mode 100644 .changelog/8a37aa67d7244b1a849e1d3c4f040ae4.json create mode 100644 .changelog/f8600d688a904cc1828df6985b3324be.json diff --git a/.changelog/18daa891967d40b28ab7d73705b451a2.json b/.changelog/18daa891967d40b28ab7d73705b451a2.json new file mode 100644 index 00000000000..b9556e9c7c7 --- /dev/null +++ b/.changelog/18daa891967d40b28ab7d73705b451a2.json @@ -0,0 +1,8 @@ +{ + "id": "18daa891-967d-40b2-8ab7-d73705b451a2", + "type": "feature", + "description": "Expose ProfilerConfig attribute in SageMaker Search API response.", + "modules": [ + "service/sagemaker" + ] +} \ No newline at end of file diff --git a/.changelog/725d40a1698045a3b0853d96c615158a.json b/.changelog/725d40a1698045a3b0853d96c615158a.json new file mode 100644 index 00000000000..9d0651abaff --- /dev/null +++ b/.changelog/725d40a1698045a3b0853d96c615158a.json @@ -0,0 +1,8 @@ +{ + "id": "725d40a1-6980-45a3-b085-3d96c615158a", + "type": "feature", + "description": "Add multiple customer error code to handle customer caused failure when managing EKS node groups", + "modules": [ + "service/eks" + ] +} \ No newline at end of file diff --git a/.changelog/814f0818c064439088ef873f775fdde3.json b/.changelog/814f0818c064439088ef873f775fdde3.json new file mode 100644 index 00000000000..88d27f04265 --- /dev/null +++ b/.changelog/814f0818c064439088ef873f775fdde3.json @@ -0,0 +1,8 @@ +{ + "id": "814f0818-c064-4390-88ef-873f775fdde3", + "type": "feature", + "description": "SDK and documentation updates for Amazon Elastic Block Store API", + "modules": [ + "service/ebs" + ] +} \ No newline at end of file diff --git a/.changelog/8a37aa67d7244b1a849e1d3c4f040ae4.json b/.changelog/8a37aa67d7244b1a849e1d3c4f040ae4.json new file mode 100644 index 00000000000..00a051cf6f4 --- /dev/null +++ b/.changelog/8a37aa67d7244b1a849e1d3c4f040ae4.json @@ -0,0 +1,8 @@ +{ + "id": "8a37aa67-d724-4b1a-849e-1d3c4f040ae4", + "type": "feature", + "description": "SDK and documentation updates for Amazon Elastic Block Store APIs", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/f8600d688a904cc1828df6985b3324be.json b/.changelog/f8600d688a904cc1828df6985b3324be.json new file mode 100644 index 00000000000..b9492249460 --- /dev/null +++ b/.changelog/f8600d688a904cc1828df6985b3324be.json @@ -0,0 +1,8 @@ +{ + "id": "f8600d68-8a90-4cc1-828d-f6985b3324be", + "type": "feature", + "description": "This release updates validation for instance types used in the AllowedInstanceTypes and ExcludedInstanceTypes parameters of the InstanceRequirements property of a MixedInstancesPolicy.", + "modules": [ + "service/autoscaling" + ] +} \ No newline at end of file diff --git a/service/autoscaling/api_op_CompleteLifecycleAction.go b/service/autoscaling/api_op_CompleteLifecycleAction.go index 0d583e1f64c..0b684364f7b 100644 --- a/service/autoscaling/api_op_CompleteLifecycleAction.go +++ b/service/autoscaling/api_op_CompleteLifecycleAction.go @@ -29,7 +29,7 @@ import ( // - If you finish before the timeout period ends, send a callback by using the // CompleteLifecycleAction API call. // -// For more information, see Amazon EC2 Auto Scaling lifecycle hooks (https://docs.aws.amazon.com/autoscaling/ec2/userguide/lifecycle-hooks.html) +// For more information, see Complete a lifecycle action (https://docs.aws.amazon.com/autoscaling/ec2/userguide/completing-lifecycle-hooks.html) // in the Amazon EC2 Auto Scaling User Guide. func (c *Client) CompleteLifecycleAction(ctx context.Context, params *CompleteLifecycleActionInput, optFns ...func(*Options)) (*CompleteLifecycleActionOutput, error) { if params == nil { diff --git a/service/autoscaling/api_op_DescribeWarmPool.go b/service/autoscaling/api_op_DescribeWarmPool.go index b9bb604919c..824d2e3557e 100644 --- a/service/autoscaling/api_op_DescribeWarmPool.go +++ b/service/autoscaling/api_op_DescribeWarmPool.go @@ -4,6 +4,7 @@ package autoscaling import ( "context" + "fmt" awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" "github.com/aws/aws-sdk-go-v2/aws/signer/v4" "github.com/aws/aws-sdk-go-v2/service/autoscaling/types" @@ -133,6 +134,97 @@ func (c *Client) addOperationDescribeWarmPoolMiddlewares(stack *middleware.Stack return nil } +// DescribeWarmPoolAPIClient is a client that implements the DescribeWarmPool +// operation. +type DescribeWarmPoolAPIClient interface { + DescribeWarmPool(context.Context, *DescribeWarmPoolInput, ...func(*Options)) (*DescribeWarmPoolOutput, error) +} + +var _ DescribeWarmPoolAPIClient = (*Client)(nil) + +// DescribeWarmPoolPaginatorOptions is the paginator options for DescribeWarmPool +type DescribeWarmPoolPaginatorOptions struct { + // The maximum number of instances to return with this call. The maximum value is + // 50 . + Limit int32 + + // Set to true if pagination should stop if the service returns a pagination token + // that matches the most recent token provided to the service. + StopOnDuplicateToken bool +} + +// DescribeWarmPoolPaginator is a paginator for DescribeWarmPool +type DescribeWarmPoolPaginator struct { + options DescribeWarmPoolPaginatorOptions + client DescribeWarmPoolAPIClient + params *DescribeWarmPoolInput + nextToken *string + firstPage bool +} + +// NewDescribeWarmPoolPaginator returns a new DescribeWarmPoolPaginator +func NewDescribeWarmPoolPaginator(client DescribeWarmPoolAPIClient, params *DescribeWarmPoolInput, optFns ...func(*DescribeWarmPoolPaginatorOptions)) *DescribeWarmPoolPaginator { + if params == nil { + params = &DescribeWarmPoolInput{} + } + + options := DescribeWarmPoolPaginatorOptions{} + if params.MaxRecords != nil { + options.Limit = *params.MaxRecords + } + + for _, fn := range optFns { + fn(&options) + } + + return &DescribeWarmPoolPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *DescribeWarmPoolPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next DescribeWarmPool page. +func (p *DescribeWarmPoolPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeWarmPoolOutput, error) { + if !p.HasMorePages() { + return nil, fmt.Errorf("no more pages available") + } + + params := *p.params + params.NextToken = p.nextToken + + var limit *int32 + if p.options.Limit > 0 { + limit = &p.options.Limit + } + params.MaxRecords = limit + + result, err := p.client.DescribeWarmPool(ctx, ¶ms, optFns...) + if err != nil { + return nil, err + } + p.firstPage = false + + prevToken := p.nextToken + p.nextToken = result.NextToken + + if p.options.StopOnDuplicateToken && + prevToken != nil && + p.nextToken != nil && + *prevToken == *p.nextToken { + p.nextToken = nil + } + + return result, nil +} + func newServiceMetadataMiddleware_opDescribeWarmPool(region string) *awsmiddleware.RegisterServiceMetadata { return &awsmiddleware.RegisterServiceMetadata{ Region: region, diff --git a/service/autoscaling/api_op_DetachTrafficSources.go b/service/autoscaling/api_op_DetachTrafficSources.go index 22d24442a86..c8156903597 100644 --- a/service/autoscaling/api_op_DetachTrafficSources.go +++ b/service/autoscaling/api_op_DetachTrafficSources.go @@ -12,10 +12,10 @@ import ( ) // Detaches one or more traffic sources from the specified Auto Scaling group. -// When you detach a taffic, it enters the Removing state while deregistering the -// instances in the group. When all instances are deregistered, then you can no -// longer describe the traffic source using the DescribeTrafficSources API call. -// The instances continue to run. +// When you detach a traffic source, it enters the Removing state while +// deregistering the instances in the group. When all instances are deregistered, +// then you can no longer describe the traffic source using the +// DescribeTrafficSources API call. The instances continue to run. func (c *Client) DetachTrafficSources(ctx context.Context, params *DetachTrafficSourcesInput, optFns ...func(*Options)) (*DetachTrafficSourcesOutput, error) { if params == nil { params = &DetachTrafficSourcesInput{} diff --git a/service/autoscaling/api_op_PutScalingPolicy.go b/service/autoscaling/api_op_PutScalingPolicy.go index 19ecaae524f..50db6c93a92 100644 --- a/service/autoscaling/api_op_PutScalingPolicy.go +++ b/service/autoscaling/api_op_PutScalingPolicy.go @@ -120,7 +120,7 @@ type PutScalingPolicyInput struct { // The amount by which to scale, based on the specified adjustment type. A // positive value adds to the current capacity while a negative number removes from - // the current capacity. For exact capacity, you must specify a positive value. + // the current capacity. For exact capacity, you must specify a non-negative value. // Required if the policy type is SimpleScaling . (Not used with any other policy // type.) ScalingAdjustment *int32 diff --git a/service/autoscaling/api_op_RollbackInstanceRefresh.go b/service/autoscaling/api_op_RollbackInstanceRefresh.go index 4aba2656241..587d654f728 100644 --- a/service/autoscaling/api_op_RollbackInstanceRefresh.go +++ b/service/autoscaling/api_op_RollbackInstanceRefresh.go @@ -46,6 +46,8 @@ func (c *Client) RollbackInstanceRefresh(ctx context.Context, params *RollbackIn type RollbackInstanceRefreshInput struct { // The name of the Auto Scaling group. + // + // This member is required. AutoScalingGroupName *string noSmithyDocumentSerde @@ -108,6 +110,9 @@ func (c *Client) addOperationRollbackInstanceRefreshMiddlewares(stack *middlewar if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { return err } + if err = addOpRollbackInstanceRefreshValidationMiddleware(stack); err != nil { + return err + } if err = stack.Initialize.Add(newServiceMetadataMiddleware_opRollbackInstanceRefresh(options.Region), middleware.Before); err != nil { return err } diff --git a/service/autoscaling/types/types.go b/service/autoscaling/types/types.go index 00b6492ee8a..2c8509274e3 100644 --- a/service/autoscaling/types/types.go +++ b/service/autoscaling/types/types.go @@ -2301,10 +2301,7 @@ type StepAdjustment struct { // The amount by which to scale, based on the specified adjustment type. A // positive value adds to the current capacity while a negative number removes from - // the current capacity. The amount by which to scale. The adjustment is based on - // the value that you specified in the AdjustmentType property (either an absolute - // number or a percentage). A positive value adds to the current capacity and a - // negative number subtracts from the current capacity. + // the current capacity. For exact capacity, you must specify a non-negative value. // // This member is required. ScalingAdjustment *int32 diff --git a/service/autoscaling/validators.go b/service/autoscaling/validators.go index a782cedc5ea..5ca37b100d3 100644 --- a/service/autoscaling/validators.go +++ b/service/autoscaling/validators.go @@ -850,6 +850,26 @@ func (m *validateOpResumeProcesses) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpRollbackInstanceRefresh struct { +} + +func (*validateOpRollbackInstanceRefresh) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpRollbackInstanceRefresh) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*RollbackInstanceRefreshInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpRollbackInstanceRefreshInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpSetDesiredCapacity struct { } @@ -1158,6 +1178,10 @@ func addOpResumeProcessesValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpResumeProcesses{}, middleware.After) } +func addOpRollbackInstanceRefreshValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpRollbackInstanceRefresh{}, middleware.After) +} + func addOpSetDesiredCapacityValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpSetDesiredCapacity{}, middleware.After) } @@ -2714,6 +2738,21 @@ func validateOpResumeProcessesInput(v *ResumeProcessesInput) error { } } +func validateOpRollbackInstanceRefreshInput(v *RollbackInstanceRefreshInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "RollbackInstanceRefreshInput"} + if v.AutoScalingGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("AutoScalingGroupName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpSetDesiredCapacityInput(v *SetDesiredCapacityInput) error { if v == nil { return nil diff --git a/service/ebs/api_op_CompleteSnapshot.go b/service/ebs/api_op_CompleteSnapshot.go index 35c0d876a46..05c97bb91a0 100644 --- a/service/ebs/api_op_CompleteSnapshot.go +++ b/service/ebs/api_op_CompleteSnapshot.go @@ -13,7 +13,11 @@ import ( // Seals and completes the snapshot after all of the required blocks of data have // been written to it. Completing the snapshot changes the status to completed . -// You cannot write new blocks to a snapshot after it has been completed. +// You cannot write new blocks to a snapshot after it has been completed. You +// should always retry requests that receive server ( 5xx ) error responses, and +// ThrottlingException and RequestThrottledException client error responses. For +// more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) CompleteSnapshot(ctx context.Context, params *CompleteSnapshotInput, optFns ...func(*Options)) (*CompleteSnapshotOutput, error) { if params == nil { params = &CompleteSnapshotInput{} diff --git a/service/ebs/api_op_GetSnapshotBlock.go b/service/ebs/api_op_GetSnapshotBlock.go index d2cbd72b41f..e76572d3c31 100644 --- a/service/ebs/api_op_GetSnapshotBlock.go +++ b/service/ebs/api_op_GetSnapshotBlock.go @@ -12,7 +12,11 @@ import ( "io" ) -// Returns the data in a block in an Amazon Elastic Block Store snapshot. +// Returns the data in a block in an Amazon Elastic Block Store snapshot. You +// should always retry requests that receive server ( 5xx ) error responses, and +// ThrottlingException and RequestThrottledException client error responses. For +// more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) GetSnapshotBlock(ctx context.Context, params *GetSnapshotBlockInput, optFns ...func(*Options)) (*GetSnapshotBlockOutput, error) { if params == nil { params = &GetSnapshotBlockInput{} diff --git a/service/ebs/api_op_ListChangedBlocks.go b/service/ebs/api_op_ListChangedBlocks.go index 8bc20d83647..799d4cac8f9 100644 --- a/service/ebs/api_op_ListChangedBlocks.go +++ b/service/ebs/api_op_ListChangedBlocks.go @@ -14,7 +14,11 @@ import ( ) // Returns information about the blocks that are different between two Amazon -// Elastic Block Store snapshots of the same volume/snapshot lineage. +// Elastic Block Store snapshots of the same volume/snapshot lineage. You should +// always retry requests that receive server ( 5xx ) error responses, and +// ThrottlingException and RequestThrottledException client error responses. For +// more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) ListChangedBlocks(ctx context.Context, params *ListChangedBlocksInput, optFns ...func(*Options)) (*ListChangedBlocksOutput, error) { if params == nil { params = &ListChangedBlocksInput{} diff --git a/service/ebs/api_op_ListSnapshotBlocks.go b/service/ebs/api_op_ListSnapshotBlocks.go index 93c5ea25432..ebc4be3052d 100644 --- a/service/ebs/api_op_ListSnapshotBlocks.go +++ b/service/ebs/api_op_ListSnapshotBlocks.go @@ -14,6 +14,10 @@ import ( ) // Returns information about the blocks in an Amazon Elastic Block Store snapshot. +// You should always retry requests that receive server ( 5xx ) error responses, +// and ThrottlingException and RequestThrottledException client error responses. +// For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) ListSnapshotBlocks(ctx context.Context, params *ListSnapshotBlocksInput, optFns ...func(*Options)) (*ListSnapshotBlocksOutput, error) { if params == nil { params = &ListSnapshotBlocksInput{} diff --git a/service/ebs/api_op_PutSnapshotBlock.go b/service/ebs/api_op_PutSnapshotBlock.go index 6396e48fef4..853e18a3b21 100644 --- a/service/ebs/api_op_PutSnapshotBlock.go +++ b/service/ebs/api_op_PutSnapshotBlock.go @@ -14,7 +14,11 @@ import ( // Writes a block of data to a snapshot. If the specified block contains data, the // existing data is overwritten. The target snapshot must be in the pending state. -// Data written to a snapshot must be aligned with 512-KiB sectors. +// Data written to a snapshot must be aligned with 512-KiB sectors. You should +// always retry requests that receive server ( 5xx ) error responses, and +// ThrottlingException and RequestThrottledException client error responses. For +// more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) PutSnapshotBlock(ctx context.Context, params *PutSnapshotBlockInput, optFns ...func(*Options)) (*PutSnapshotBlockOutput, error) { if params == nil { params = &PutSnapshotBlockInput{} diff --git a/service/ebs/api_op_StartSnapshot.go b/service/ebs/api_op_StartSnapshot.go index e155826a79c..91c34145994 100644 --- a/service/ebs/api_op_StartSnapshot.go +++ b/service/ebs/api_op_StartSnapshot.go @@ -15,7 +15,11 @@ import ( // Creates a new Amazon EBS snapshot. The new snapshot enters the pending state // after the request completes. After creating the snapshot, use PutSnapshotBlock (https://docs.aws.amazon.com/ebs/latest/APIReference/API_PutSnapshotBlock.html) -// to write blocks of data to the snapshot. +// to write blocks of data to the snapshot. You should always retry requests that +// receive server ( 5xx ) error responses, and ThrottlingException and +// RequestThrottledException client error responses. For more information see +// Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// in the Amazon Elastic Compute Cloud User Guide. func (c *Client) StartSnapshot(ctx context.Context, params *StartSnapshotInput, optFns ...func(*Options)) (*StartSnapshotOutput, error) { if params == nil { params = &StartSnapshotInput{} @@ -124,6 +128,9 @@ type StartSnapshotOutput struct { // The ID of the snapshot. SnapshotId *string + // Reserved for future use. + SseType types.SSEType + // The timestamp when the snapshot was created. StartTime *time.Time diff --git a/service/ebs/deserializers.go b/service/ebs/deserializers.go index 62770bd53b9..a8a2a3d591a 100644 --- a/service/ebs/deserializers.go +++ b/service/ebs/deserializers.go @@ -1088,6 +1088,15 @@ func awsRestjson1_deserializeOpDocumentStartSnapshotOutput(v **StartSnapshotOutp sv.SnapshotId = ptr.String(jtv) } + case "SseType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SSEType to be of type string, got %T instead", value) + } + sv.SseType = types.SSEType(jtv) + } + case "StartTime": if value != nil { switch jtv := value.(type) { diff --git a/service/ebs/types/enums.go b/service/ebs/types/enums.go index 8dfc95a0b2e..f725e5f3658 100644 --- a/service/ebs/types/enums.go +++ b/service/ebs/types/enums.go @@ -78,7 +78,9 @@ type ResourceNotFoundExceptionReason string // Enum values for ResourceNotFoundExceptionReason const ( ResourceNotFoundExceptionReasonSnapshotNotFound ResourceNotFoundExceptionReason = "SNAPSHOT_NOT_FOUND" + ResourceNotFoundExceptionReasonGrantNotFound ResourceNotFoundExceptionReason = "GRANT_NOT_FOUND" ResourceNotFoundExceptionReasonDependencyResourceNotFound ResourceNotFoundExceptionReason = "DEPENDENCY_RESOURCE_NOT_FOUND" + ResourceNotFoundExceptionReasonImageNotFound ResourceNotFoundExceptionReason = "IMAGE_NOT_FOUND" ) // Values returns all known values for ResourceNotFoundExceptionReason. Note that @@ -88,7 +90,9 @@ const ( func (ResourceNotFoundExceptionReason) Values() []ResourceNotFoundExceptionReason { return []ResourceNotFoundExceptionReason{ "SNAPSHOT_NOT_FOUND", + "GRANT_NOT_FOUND", "DEPENDENCY_RESOURCE_NOT_FOUND", + "IMAGE_NOT_FOUND", } } @@ -109,6 +113,26 @@ func (ServiceQuotaExceededExceptionReason) Values() []ServiceQuotaExceededExcept } } +type SSEType string + +// Enum values for SSEType +const ( + SSETypeSseEbs SSEType = "sse-ebs" + SSETypeSseKms SSEType = "sse-kms" + SSETypeNone SSEType = "none" +) + +// Values returns all known values for SSEType. Note that this can be expanded in +// the future, and so it is only as up to date as the client. The ordering of this +// slice is not guaranteed to be stable across updates. +func (SSEType) Values() []SSEType { + return []SSEType{ + "sse-ebs", + "sse-kms", + "none", + } +} + type Status string // Enum values for Status @@ -136,6 +160,7 @@ const ( ValidationExceptionReasonInvalidCustomerKey ValidationExceptionReason = "INVALID_CUSTOMER_KEY" ValidationExceptionReasonInvalidPageToken ValidationExceptionReason = "INVALID_PAGE_TOKEN" ValidationExceptionReasonInvalidBlockToken ValidationExceptionReason = "INVALID_BLOCK_TOKEN" + ValidationExceptionReasonInvalidGrantToken ValidationExceptionReason = "INVALID_GRANT_TOKEN" ValidationExceptionReasonInvalidSnapshotId ValidationExceptionReason = "INVALID_SNAPSHOT_ID" ValidationExceptionReasonUnrelatedSnapshots ValidationExceptionReason = "UNRELATED_SNAPSHOTS" ValidationExceptionReasonInvalidBlock ValidationExceptionReason = "INVALID_BLOCK" @@ -145,6 +170,8 @@ const ( ValidationExceptionReasonInvalidParameterValue ValidationExceptionReason = "INVALID_PARAMETER_VALUE" ValidationExceptionReasonInvalidVolumeSize ValidationExceptionReason = "INVALID_VOLUME_SIZE" ValidationExceptionReasonConflictingBlockUpdate ValidationExceptionReason = "CONFLICTING_BLOCK_UPDATE" + ValidationExceptionReasonInvalidImageId ValidationExceptionReason = "INVALID_IMAGE_ID" + ValidationExceptionReasonWriteRequestTimeout ValidationExceptionReason = "WRITE_REQUEST_TIMEOUT" ) // Values returns all known values for ValidationExceptionReason. Note that this @@ -155,6 +182,7 @@ func (ValidationExceptionReason) Values() []ValidationExceptionReason { "INVALID_CUSTOMER_KEY", "INVALID_PAGE_TOKEN", "INVALID_BLOCK_TOKEN", + "INVALID_GRANT_TOKEN", "INVALID_SNAPSHOT_ID", "UNRELATED_SNAPSHOTS", "INVALID_BLOCK", @@ -164,5 +192,7 @@ func (ValidationExceptionReason) Values() []ValidationExceptionReason { "INVALID_PARAMETER_VALUE", "INVALID_VOLUME_SIZE", "CONFLICTING_BLOCK_UPDATE", + "INVALID_IMAGE_ID", + "WRITE_REQUEST_TIMEOUT", } } diff --git a/service/ebs/types/errors.go b/service/ebs/types/errors.go index 251478d928e..6888d9ad28f 100644 --- a/service/ebs/types/errors.go +++ b/service/ebs/types/errors.go @@ -89,7 +89,8 @@ func (e *ConflictException) ErrorCode() string { } func (e *ConflictException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } -// An internal error has occurred. +// An internal error has occurred. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// . type InternalServerException struct { Message *string @@ -115,8 +116,9 @@ func (e *InternalServerException) ErrorCode() string { } func (e *InternalServerException) ErrorFault() smithy.ErrorFault { return smithy.FaultServer } -// The number of API requests has exceed the maximum allowed API request -// throttling limit. +// The number of API requests has exceeded the maximum allowed API request +// throttling limit for the snapshot. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) +// . type RequestThrottledException struct { Message *string diff --git a/service/ec2/api_op_CreateSnapshot.go b/service/ec2/api_op_CreateSnapshot.go index 886029a3ddb..63ff110a35c 100644 --- a/service/ec2/api_op_CreateSnapshot.go +++ b/service/ec2/api_op_CreateSnapshot.go @@ -136,6 +136,9 @@ type CreateSnapshotOutput struct { // created. SnapshotId *string + // Reserved for future use. + SseType types.SSEType + // The time stamp when the snapshot was initiated. StartTime *time.Time diff --git a/service/ec2/api_op_CreateVolume.go b/service/ec2/api_op_CreateVolume.go index d901c748863..3745e3d9473 100644 --- a/service/ec2/api_op_CreateVolume.go +++ b/service/ec2/api_op_CreateVolume.go @@ -186,6 +186,9 @@ type CreateVolumeOutput struct { // The snapshot from which the volume was created, if applicable. SnapshotId *string + // Reserved for future use. + SseType types.SSEType + // The volume state. State types.VolumeState diff --git a/service/ec2/api_op_DescribeStoreImageTasks.go b/service/ec2/api_op_DescribeStoreImageTasks.go index f8550dcd710..a238737d0e2 100644 --- a/service/ec2/api_op_DescribeStoreImageTasks.go +++ b/service/ec2/api_op_DescribeStoreImageTasks.go @@ -9,7 +9,11 @@ import ( "github.com/aws/aws-sdk-go-v2/aws/signer/v4" "github.com/aws/aws-sdk-go-v2/service/ec2/types" "github.com/aws/smithy-go/middleware" + smithytime "github.com/aws/smithy-go/time" smithyhttp "github.com/aws/smithy-go/transport/http" + smithywaiter "github.com/aws/smithy-go/waiter" + "github.com/jmespath/go-jmespath" + "time" ) // Describes the progress of the AMI store tasks. You can describe the store tasks @@ -243,6 +247,231 @@ func (p *DescribeStoreImageTasksPaginator) NextPage(ctx context.Context, optFns return result, nil } +// StoreImageTaskCompleteWaiterOptions are waiter options for +// StoreImageTaskCompleteWaiter +type StoreImageTaskCompleteWaiterOptions struct { + + // Set of options to modify how an operation is invoked. These apply to all + // operations invoked for this client. Use functional options on operation call to + // modify this list for per operation behavior. + APIOptions []func(*middleware.Stack) error + + // MinDelay is the minimum amount of time to delay between retries. If unset, + // StoreImageTaskCompleteWaiter will use default minimum delay of 5 seconds. Note + // that MinDelay must resolve to a value lesser than or equal to the MaxDelay. + MinDelay time.Duration + + // MaxDelay is the maximum amount of time to delay between retries. If unset or + // set to zero, StoreImageTaskCompleteWaiter will use default max delay of 120 + // seconds. Note that MaxDelay must resolve to value greater than or equal to the + // MinDelay. + MaxDelay time.Duration + + // LogWaitAttempts is used to enable logging for waiter retry attempts + LogWaitAttempts bool + + // Retryable is function that can be used to override the service defined + // waiter-behavior based on operation output, or returned error. This function is + // used by the waiter to decide if a state is retryable or a terminal state. By + // default service-modeled logic will populate this option. This option can thus be + // used to define a custom waiter state with fall-back to service-modeled waiter + // state mutators.The function returns an error in case of a failure state. In case + // of retry state, this function returns a bool value of true and nil error, while + // in case of success it returns a bool value of false and nil error. + Retryable func(context.Context, *DescribeStoreImageTasksInput, *DescribeStoreImageTasksOutput, error) (bool, error) +} + +// StoreImageTaskCompleteWaiter defines the waiters for StoreImageTaskComplete +type StoreImageTaskCompleteWaiter struct { + client DescribeStoreImageTasksAPIClient + + options StoreImageTaskCompleteWaiterOptions +} + +// NewStoreImageTaskCompleteWaiter constructs a StoreImageTaskCompleteWaiter. +func NewStoreImageTaskCompleteWaiter(client DescribeStoreImageTasksAPIClient, optFns ...func(*StoreImageTaskCompleteWaiterOptions)) *StoreImageTaskCompleteWaiter { + options := StoreImageTaskCompleteWaiterOptions{} + options.MinDelay = 5 * time.Second + options.MaxDelay = 120 * time.Second + options.Retryable = storeImageTaskCompleteStateRetryable + + for _, fn := range optFns { + fn(&options) + } + return &StoreImageTaskCompleteWaiter{ + client: client, + options: options, + } +} + +// Wait calls the waiter function for StoreImageTaskComplete waiter. The +// maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is +// required and must be greater than zero. +func (w *StoreImageTaskCompleteWaiter) Wait(ctx context.Context, params *DescribeStoreImageTasksInput, maxWaitDur time.Duration, optFns ...func(*StoreImageTaskCompleteWaiterOptions)) error { + _, err := w.WaitForOutput(ctx, params, maxWaitDur, optFns...) + return err +} + +// WaitForOutput calls the waiter function for StoreImageTaskComplete waiter and +// returns the output of the successful operation. The maxWaitDur is the maximum +// wait duration the waiter will wait. The maxWaitDur is required and must be +// greater than zero. +func (w *StoreImageTaskCompleteWaiter) WaitForOutput(ctx context.Context, params *DescribeStoreImageTasksInput, maxWaitDur time.Duration, optFns ...func(*StoreImageTaskCompleteWaiterOptions)) (*DescribeStoreImageTasksOutput, error) { + if maxWaitDur <= 0 { + return nil, fmt.Errorf("maximum wait time for waiter must be greater than zero") + } + + options := w.options + for _, fn := range optFns { + fn(&options) + } + + if options.MaxDelay <= 0 { + options.MaxDelay = 120 * time.Second + } + + if options.MinDelay > options.MaxDelay { + return nil, fmt.Errorf("minimum waiter delay %v must be lesser than or equal to maximum waiter delay of %v.", options.MinDelay, options.MaxDelay) + } + + ctx, cancelFn := context.WithTimeout(ctx, maxWaitDur) + defer cancelFn() + + logger := smithywaiter.Logger{} + remainingTime := maxWaitDur + + var attempt int64 + for { + + attempt++ + apiOptions := options.APIOptions + start := time.Now() + + if options.LogWaitAttempts { + logger.Attempt = attempt + apiOptions = append([]func(*middleware.Stack) error{}, options.APIOptions...) + apiOptions = append(apiOptions, logger.AddLogger) + } + + out, err := w.client.DescribeStoreImageTasks(ctx, params, func(o *Options) { + o.APIOptions = append(o.APIOptions, apiOptions...) + }) + + retryable, err := options.Retryable(ctx, params, out, err) + if err != nil { + return nil, err + } + if !retryable { + return out, nil + } + + remainingTime -= time.Since(start) + if remainingTime < options.MinDelay || remainingTime <= 0 { + break + } + + // compute exponential backoff between waiter retries + delay, err := smithywaiter.ComputeDelay( + attempt, options.MinDelay, options.MaxDelay, remainingTime, + ) + if err != nil { + return nil, fmt.Errorf("error computing waiter delay, %w", err) + } + + remainingTime -= delay + // sleep for the delay amount before invoking a request + if err := smithytime.SleepWithContext(ctx, delay); err != nil { + return nil, fmt.Errorf("request cancelled while waiting, %w", err) + } + } + return nil, fmt.Errorf("exceeded max wait time for StoreImageTaskComplete waiter") +} + +func storeImageTaskCompleteStateRetryable(ctx context.Context, input *DescribeStoreImageTasksInput, output *DescribeStoreImageTasksOutput, err error) (bool, error) { + + if err == nil { + pathValue, err := jmespath.Search("StoreImageTaskResults[].StoreTaskState", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "Completed" + var match = true + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + if len(listOfValues) == 0 { + match = false + } + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) != expectedValue { + match = false + } + } + + if match { + return false, nil + } + } + + if err == nil { + pathValue, err := jmespath.Search("StoreImageTaskResults[].StoreTaskState", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "Failed" + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) == expectedValue { + return false, fmt.Errorf("waiter state transitioned to Failure") + } + } + } + + if err == nil { + pathValue, err := jmespath.Search("StoreImageTaskResults[].StoreTaskState", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "InProgress" + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) == expectedValue { + return true, nil + } + } + } + + return true, nil +} + func newServiceMetadataMiddleware_opDescribeStoreImageTasks(region string) *awsmiddleware.RegisterServiceMetadata { return &awsmiddleware.RegisterServiceMetadata{ Region: region, diff --git a/service/ec2/api_op_GetEbsEncryptionByDefault.go b/service/ec2/api_op_GetEbsEncryptionByDefault.go index 5cabc73eec1..2cdb63b4f54 100644 --- a/service/ec2/api_op_GetEbsEncryptionByDefault.go +++ b/service/ec2/api_op_GetEbsEncryptionByDefault.go @@ -6,6 +6,7 @@ import ( "context" awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" "github.com/aws/smithy-go/middleware" smithyhttp "github.com/aws/smithy-go/transport/http" ) @@ -44,6 +45,9 @@ type GetEbsEncryptionByDefaultOutput struct { // Indicates whether encryption by default is enabled. EbsEncryptionByDefault *bool + // Reserved for future use. + SseType types.SSEType + // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata diff --git a/service/ec2/api_op_RestoreSnapshotFromRecycleBin.go b/service/ec2/api_op_RestoreSnapshotFromRecycleBin.go index 8fd20c43f5b..014ed0b0257 100644 --- a/service/ec2/api_op_RestoreSnapshotFromRecycleBin.go +++ b/service/ec2/api_op_RestoreSnapshotFromRecycleBin.go @@ -68,6 +68,9 @@ type RestoreSnapshotFromRecycleBinOutput struct { // The ID of the snapshot. SnapshotId *string + // Reserved for future use. + SseType types.SSEType + // The time stamp when the snapshot was initiated. StartTime *time.Time diff --git a/service/ec2/deserializers.go b/service/ec2/deserializers.go index 563e68e4844..da180fe0477 100644 --- a/service/ec2/deserializers.go +++ b/service/ec2/deserializers.go @@ -111553,6 +111553,19 @@ func awsEc2query_deserializeDocumentSnapshot(v **types.Snapshot, decoder smithyx sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("startTime", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -111993,6 +112006,19 @@ func awsEc2query_deserializeDocumentSnapshotInfo(v **types.SnapshotInfo, decoder sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("startTime", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -129044,6 +129070,19 @@ func awsEc2query_deserializeDocumentVolume(v **types.Volume, decoder smithyxml.N sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("status", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -138430,6 +138469,19 @@ func awsEc2query_deserializeOpDocumentCreateSnapshotOutput(v **CreateSnapshotOut sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("startTime", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -139782,6 +139834,19 @@ func awsEc2query_deserializeOpDocumentCreateVolumeOutput(v **CreateVolumeOutput, sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("status", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -153978,6 +154043,19 @@ func awsEc2query_deserializeOpDocumentGetEbsEncryptionByDefaultOutput(v **GetEbs sv.EbsEncryptionByDefault = ptr.Bool(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + default: // Do nothing and ignore the unexpected tag element err = decoder.Decoder.Skip() @@ -160927,6 +161005,19 @@ func awsEc2query_deserializeOpDocumentRestoreSnapshotFromRecycleBinOutput(v **Re sv.SnapshotId = ptr.String(xtv) } + case strings.EqualFold("sseType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SseType = types.SSEType(xtv) + } + case strings.EqualFold("startTime", t.Name.Local): val, err := decoder.Value() if err != nil { diff --git a/service/ec2/types/enums.go b/service/ec2/types/enums.go index c4853fb4189..fa5ba6e15d8 100644 --- a/service/ec2/types/enums.go +++ b/service/ec2/types/enums.go @@ -6523,6 +6523,26 @@ func (SpreadLevel) Values() []SpreadLevel { } } +type SSEType string + +// Enum values for SSEType +const ( + SSETypeSseEbs SSEType = "sse-ebs" + SSETypeSseKms SSEType = "sse-kms" + SSETypeNone SSEType = "none" +) + +// Values returns all known values for SSEType. Note that this can be expanded in +// the future, and so it is only as up to date as the client. The ordering of this +// slice is not guaranteed to be stable across updates. +func (SSEType) Values() []SSEType { + return []SSEType{ + "sse-ebs", + "sse-kms", + "none", + } +} + type State string // Enum values for State diff --git a/service/ec2/types/types.go b/service/ec2/types/types.go index 063b95afdc7..745a9544493 100644 --- a/service/ec2/types/types.go +++ b/service/ec2/types/types.go @@ -13311,6 +13311,9 @@ type Snapshot struct { // created. SnapshotId *string + // Reserved for future use. + SseType SSEType + // The time stamp when the snapshot was initiated. StartTime *time.Time @@ -13423,6 +13426,9 @@ type SnapshotInfo struct { // Snapshot id that can be used to describe this snapshot. SnapshotId *string + // Reserved for future use. + SseType SSEType + // Time this snapshot was started. This is the same for all snapshots initiated by // the same request. StartTime *time.Time @@ -16782,6 +16788,9 @@ type Volume struct { // The snapshot from which the volume was created, if applicable. SnapshotId *string + // Reserved for future use. + SseType SSEType + // The volume state. State VolumeState diff --git a/service/eks/types/enums.go b/service/eks/types/enums.go index 6e080d8de44..de715461f7d 100644 --- a/service/eks/types/enums.go +++ b/service/eks/types/enums.go @@ -340,25 +340,39 @@ type NodegroupIssueCode string // Enum values for NodegroupIssueCode const ( - NodegroupIssueCodeAutoScalingGroupNotFound NodegroupIssueCode = "AutoScalingGroupNotFound" - NodegroupIssueCodeAutoScalingGroupInvalidConfiguration NodegroupIssueCode = "AutoScalingGroupInvalidConfiguration" - NodegroupIssueCodeEc2SecurityGroupNotFound NodegroupIssueCode = "Ec2SecurityGroupNotFound" - NodegroupIssueCodeEc2SecurityGroupDeletionFailure NodegroupIssueCode = "Ec2SecurityGroupDeletionFailure" - NodegroupIssueCodeEc2LaunchTemplateNotFound NodegroupIssueCode = "Ec2LaunchTemplateNotFound" - NodegroupIssueCodeEc2LaunchTemplateVersionMismatch NodegroupIssueCode = "Ec2LaunchTemplateVersionMismatch" - NodegroupIssueCodeEc2SubnetNotFound NodegroupIssueCode = "Ec2SubnetNotFound" - NodegroupIssueCodeEc2SubnetInvalidConfiguration NodegroupIssueCode = "Ec2SubnetInvalidConfiguration" - NodegroupIssueCodeIamInstanceProfileNotFound NodegroupIssueCode = "IamInstanceProfileNotFound" - NodegroupIssueCodeIamLimitExceeded NodegroupIssueCode = "IamLimitExceeded" - NodegroupIssueCodeIamNodeRoleNotFound NodegroupIssueCode = "IamNodeRoleNotFound" - NodegroupIssueCodeNodeCreationFailure NodegroupIssueCode = "NodeCreationFailure" - NodegroupIssueCodeAsgInstanceLaunchFailures NodegroupIssueCode = "AsgInstanceLaunchFailures" - NodegroupIssueCodeInstanceLimitExceeded NodegroupIssueCode = "InstanceLimitExceeded" - NodegroupIssueCodeInsufficientFreeAddresses NodegroupIssueCode = "InsufficientFreeAddresses" - NodegroupIssueCodeAccessDenied NodegroupIssueCode = "AccessDenied" - NodegroupIssueCodeInternalFailure NodegroupIssueCode = "InternalFailure" - NodegroupIssueCodeClusterUnreachable NodegroupIssueCode = "ClusterUnreachable" - NodegroupIssueCodeEc2SubnetMissingIpv6Assignment NodegroupIssueCode = "Ec2SubnetMissingIpv6Assignment" + NodegroupIssueCodeAutoScalingGroupNotFound NodegroupIssueCode = "AutoScalingGroupNotFound" + NodegroupIssueCodeAutoScalingGroupInvalidConfiguration NodegroupIssueCode = "AutoScalingGroupInvalidConfiguration" + NodegroupIssueCodeEc2SecurityGroupNotFound NodegroupIssueCode = "Ec2SecurityGroupNotFound" + NodegroupIssueCodeEc2SecurityGroupDeletionFailure NodegroupIssueCode = "Ec2SecurityGroupDeletionFailure" + NodegroupIssueCodeEc2LaunchTemplateNotFound NodegroupIssueCode = "Ec2LaunchTemplateNotFound" + NodegroupIssueCodeEc2LaunchTemplateVersionMismatch NodegroupIssueCode = "Ec2LaunchTemplateVersionMismatch" + NodegroupIssueCodeEc2SubnetNotFound NodegroupIssueCode = "Ec2SubnetNotFound" + NodegroupIssueCodeEc2SubnetInvalidConfiguration NodegroupIssueCode = "Ec2SubnetInvalidConfiguration" + NodegroupIssueCodeIamInstanceProfileNotFound NodegroupIssueCode = "IamInstanceProfileNotFound" + NodegroupIssueCodeEc2SubnetMissingIpv6Assignment NodegroupIssueCode = "Ec2SubnetMissingIpv6Assignment" + NodegroupIssueCodeIamLimitExceeded NodegroupIssueCode = "IamLimitExceeded" + NodegroupIssueCodeIamNodeRoleNotFound NodegroupIssueCode = "IamNodeRoleNotFound" + NodegroupIssueCodeNodeCreationFailure NodegroupIssueCode = "NodeCreationFailure" + NodegroupIssueCodeAsgInstanceLaunchFailures NodegroupIssueCode = "AsgInstanceLaunchFailures" + NodegroupIssueCodeInstanceLimitExceeded NodegroupIssueCode = "InstanceLimitExceeded" + NodegroupIssueCodeInsufficientFreeAddresses NodegroupIssueCode = "InsufficientFreeAddresses" + NodegroupIssueCodeAccessDenied NodegroupIssueCode = "AccessDenied" + NodegroupIssueCodeInternalFailure NodegroupIssueCode = "InternalFailure" + NodegroupIssueCodeClusterUnreachable NodegroupIssueCode = "ClusterUnreachable" + NodegroupIssueCodeAmiIdNotFound NodegroupIssueCode = "AmiIdNotFound" + NodegroupIssueCodeAutoScalingGroupOptInRequired NodegroupIssueCode = "AutoScalingGroupOptInRequired" + NodegroupIssueCodeAutoScalingGroupRateLimitExceeded NodegroupIssueCode = "AutoScalingGroupRateLimitExceeded" + NodegroupIssueCodeEc2LaunchTemplateDeletionFailure NodegroupIssueCode = "Ec2LaunchTemplateDeletionFailure" + NodegroupIssueCodeEc2LaunchTemplateInvalidConfiguration NodegroupIssueCode = "Ec2LaunchTemplateInvalidConfiguration" + NodegroupIssueCodeEc2LaunchTemplateMaxLimitExceeded NodegroupIssueCode = "Ec2LaunchTemplateMaxLimitExceeded" + NodegroupIssueCodeEc2SubnetListTooLong NodegroupIssueCode = "Ec2SubnetListTooLong" + NodegroupIssueCodeIamThrottling NodegroupIssueCode = "IamThrottling" + NodegroupIssueCodeNodeTerminationFailure NodegroupIssueCode = "NodeTerminationFailure" + NodegroupIssueCodePodEvictionFailure NodegroupIssueCode = "PodEvictionFailure" + NodegroupIssueCodeSourceEc2LaunchTemplateNotFound NodegroupIssueCode = "SourceEc2LaunchTemplateNotFound" + NodegroupIssueCodeLimitExceeded NodegroupIssueCode = "LimitExceeded" + NodegroupIssueCodeUnknown NodegroupIssueCode = "Unknown" + NodegroupIssueCodeAutoScalingGroupInstanceRefreshActive NodegroupIssueCode = "AutoScalingGroupInstanceRefreshActive" ) // Values returns all known values for NodegroupIssueCode. Note that this can be @@ -375,6 +389,7 @@ func (NodegroupIssueCode) Values() []NodegroupIssueCode { "Ec2SubnetNotFound", "Ec2SubnetInvalidConfiguration", "IamInstanceProfileNotFound", + "Ec2SubnetMissingIpv6Assignment", "IamLimitExceeded", "IamNodeRoleNotFound", "NodeCreationFailure", @@ -384,7 +399,20 @@ func (NodegroupIssueCode) Values() []NodegroupIssueCode { "AccessDenied", "InternalFailure", "ClusterUnreachable", - "Ec2SubnetMissingIpv6Assignment", + "AmiIdNotFound", + "AutoScalingGroupOptInRequired", + "AutoScalingGroupRateLimitExceeded", + "Ec2LaunchTemplateDeletionFailure", + "Ec2LaunchTemplateInvalidConfiguration", + "Ec2LaunchTemplateMaxLimitExceeded", + "Ec2SubnetListTooLong", + "IamThrottling", + "NodeTerminationFailure", + "PodEvictionFailure", + "SourceEc2LaunchTemplateNotFound", + "LimitExceeded", + "Unknown", + "AutoScalingGroupInstanceRefreshActive", } } diff --git a/service/sagemaker/deserializers.go b/service/sagemaker/deserializers.go index 570f7498762..73376db0c9e 100644 --- a/service/sagemaker/deserializers.go +++ b/service/sagemaker/deserializers.go @@ -69119,6 +69119,11 @@ func awsAwsjson11_deserializeDocumentTrainingJob(v **types.TrainingJob, value in return err } + case "ProfilerConfig": + if err := awsAwsjson11_deserializeDocumentProfilerConfig(&sv.ProfilerConfig, value); err != nil { + return err + } + case "ResourceConfig": if err := awsAwsjson11_deserializeDocumentResourceConfig(&sv.ResourceConfig, value); err != nil { return err diff --git a/service/sagemaker/types/types.go b/service/sagemaker/types/types.go index 3a709ebb1b2..e1b7749547d 100644 --- a/service/sagemaker/types/types.go +++ b/service/sagemaker/types/types.go @@ -13473,6 +13473,10 @@ type TrainingJob struct { // stored. SageMaker creates subfolders for model artifacts. OutputDataConfig *OutputDataConfig + // Configuration information for Amazon SageMaker Debugger system monitoring, + // framework profiling, and storage paths. + ProfilerConfig *ProfilerConfig + // Resources, including ML compute instances and ML storage volumes, that are // configured for model training. ResourceConfig *ResourceConfig