From 11ce965f4f0c9cb1a24f5af7157e5e8080b2d49d Mon Sep 17 00:00:00 2001 From: AWS SDK for Go v2 automation user Date: Mon, 23 Dec 2024 19:33:10 +0000 Subject: [PATCH] Regenerated Clients --- .../9e37a23d516042b0a52c51ef07be0f52.json | 8 + .../cb7255cd10bd4d0ca22f9f848081b95d.json | 8 + .../d8979807dd9544b08a018b99b3600281.json | 8 + .../e7bada8873a84995990f5a2f0dbb348b.json | 8 + service/ecr/api_op_GetAccountSetting.go | 12 +- service/ecr/api_op_PutAccountSetting.go | 15 +- service/ecrpublic/endpoints.go | 102 +-- service/ecrpublic/endpoints_test.go | 715 +----------------- service/eks/api_op_DescribeClusterVersions.go | 268 +++++++ service/eks/deserializers.go | 334 ++++++++ service/eks/generated.json | 1 + service/eks/serializers.go | 92 +++ .../api_op_DescribeClusterVersions.go.snap | 40 + service/eks/snapshot_test.go | 24 + service/eks/types/enums.go | 21 + service/eks/types/types.go | 39 +- service/glue/api_op_GetCatalogs.go | 13 +- service/glue/api_op_StartJobRun.go | 12 +- service/glue/internal/endpoints/endpoints.go | 216 ++++++ service/glue/serializers.go | 5 + service/glue/types/types.go | 12 +- .../macie2/internal/endpoints/endpoints.go | 156 ++++ .../internal/endpoints/endpoints.go | 173 ++++- 23 files changed, 1468 insertions(+), 814 deletions(-) create mode 100644 .changelog/9e37a23d516042b0a52c51ef07be0f52.json create mode 100644 .changelog/cb7255cd10bd4d0ca22f9f848081b95d.json create mode 100644 .changelog/d8979807dd9544b08a018b99b3600281.json create mode 100644 .changelog/e7bada8873a84995990f5a2f0dbb348b.json create mode 100644 service/eks/api_op_DescribeClusterVersions.go create mode 100644 service/eks/snapshot/api_op_DescribeClusterVersions.go.snap diff --git a/.changelog/9e37a23d516042b0a52c51ef07be0f52.json b/.changelog/9e37a23d516042b0a52c51ef07be0f52.json new file mode 100644 index 00000000000..45b39d31a04 --- /dev/null +++ b/.changelog/9e37a23d516042b0a52c51ef07be0f52.json @@ -0,0 +1,8 @@ +{ + "id": "9e37a23d-5160-42b0-a52c-51ef07be0f52", + "type": "feature", + "description": "This release adds support for DescribeClusterVersions API that provides important information about Kubernetes versions along with end of support dates", + "modules": [ + "service/eks" + ] +} \ No newline at end of file diff --git a/.changelog/cb7255cd10bd4d0ca22f9f848081b95d.json b/.changelog/cb7255cd10bd4d0ca22f9f848081b95d.json new file mode 100644 index 00000000000..fa74e964632 --- /dev/null +++ b/.changelog/cb7255cd10bd4d0ca22f9f848081b95d.json @@ -0,0 +1,8 @@ +{ + "id": "cb7255cd-10bd-4d0c-a22f-9f848081b95d", + "type": "documentation", + "description": "Documentation update for ECR GetAccountSetting and PutAccountSetting APIs.", + "modules": [ + "service/ecr" + ] +} \ No newline at end of file diff --git a/.changelog/d8979807dd9544b08a018b99b3600281.json b/.changelog/d8979807dd9544b08a018b99b3600281.json new file mode 100644 index 00000000000..40226e2232d --- /dev/null +++ b/.changelog/d8979807dd9544b08a018b99b3600281.json @@ -0,0 +1,8 @@ +{ + "id": "d8979807-dd95-44b0-8a01-8b99b3600281", + "type": "feature", + "description": "Add IncludeRoot parameters to GetCatalogs API to return root catalog.", + "modules": [ + "service/glue" + ] +} \ No newline at end of file diff --git a/.changelog/e7bada8873a84995990f5a2f0dbb348b.json b/.changelog/e7bada8873a84995990f5a2f0dbb348b.json new file mode 100644 index 00000000000..dc98f9fadc5 --- /dev/null +++ b/.changelog/e7bada8873a84995990f5a2f0dbb348b.json @@ -0,0 +1,8 @@ +{ + "id": "e7bada88-73a8-4995-990f-5a2f0dbb348b", + "type": "feature", + "description": "Add support for Dualstack endpoints", + "modules": [ + "service/ecrpublic" + ] +} \ No newline at end of file diff --git a/service/ecr/api_op_GetAccountSetting.go b/service/ecr/api_op_GetAccountSetting.go index dbf16325587..81d103ae23f 100644 --- a/service/ecr/api_op_GetAccountSetting.go +++ b/service/ecr/api_op_GetAccountSetting.go @@ -10,7 +10,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Retrieves the basic scan type version name. +// Retrieves the account setting value for the specified setting name. func (c *Client) GetAccountSetting(ctx context.Context, params *GetAccountSettingInput, optFns ...func(*Options)) (*GetAccountSettingOutput, error) { if params == nil { params = &GetAccountSettingInput{} @@ -28,7 +28,8 @@ func (c *Client) GetAccountSetting(ctx context.Context, params *GetAccountSettin type GetAccountSettingInput struct { - // Basic scan type version name. + // The name of the account setting, such as BASIC_SCAN_TYPE_VERSION or + // REGISTRY_POLICY_SCOPE . // // This member is required. Name *string @@ -38,11 +39,12 @@ type GetAccountSettingInput struct { type GetAccountSettingOutput struct { - // Retrieves the basic scan type version name. + // Retrieves the name of the account setting. Name *string - // Retrieves the value that specifies what basic scan type is being used: - // AWS_NATIVE or CLAIR . + // The setting value for the setting name. The following are valid values for the + // basic scan type being used: AWS_NATIVE or CLAIR . The following are valid values + // for the registry policy scope being used: V1 or V2 . Value *string // Metadata pertaining to the operation's result. diff --git a/service/ecr/api_op_PutAccountSetting.go b/service/ecr/api_op_PutAccountSetting.go index ca39fd1bd49..2075a4127ee 100644 --- a/service/ecr/api_op_PutAccountSetting.go +++ b/service/ecr/api_op_PutAccountSetting.go @@ -10,8 +10,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Allows you to change the basic scan type version by setting the name parameter -// to either CLAIR to AWS_NATIVE . +// Allows you to change the basic scan type version or registry policy scope. func (c *Client) PutAccountSetting(ctx context.Context, params *PutAccountSettingInput, optFns ...func(*Options)) (*PutAccountSettingOutput, error) { if params == nil { params = &PutAccountSettingInput{} @@ -29,13 +28,15 @@ func (c *Client) PutAccountSetting(ctx context.Context, params *PutAccountSettin type PutAccountSettingInput struct { - // Basic scan type version name. + // The name of the account setting, such as BASIC_SCAN_TYPE_VERSION or + // REGISTRY_POLICY_SCOPE . // // This member is required. Name *string - // Setting value that determines what basic scan type is being used: AWS_NATIVE or - // CLAIR . + // Setting value that is specified. The following are valid values for the basic + // scan type being used: AWS_NATIVE or CLAIR . The following are valid values for + // the registry policy scope being used: V1 or V2 . // // This member is required. Value *string @@ -45,10 +46,10 @@ type PutAccountSettingInput struct { type PutAccountSettingOutput struct { - // Retrieves the the basic scan type version name. + // Retrieves the name of the account setting. Name *string - // Retrieves the basic scan type value, either AWS_NATIVE or - . + // Retrieves the value of the specified account setting. Value *string // Metadata pertaining to the operation's result. diff --git a/service/ecrpublic/endpoints.go b/service/ecrpublic/endpoints.go index b0265a40bee..1b54a97063b 100644 --- a/service/ecrpublic/endpoints.go +++ b/service/ecrpublic/endpoints.go @@ -235,15 +235,6 @@ type EndpointParameters struct { // AWS::Region Region *string - // When true, use the dual-stack endpoint. If the configured endpoint does not - // support dual-stack, dispatching the request MAY return an error. - // - // Defaults to - // false if no value is provided. - // - // AWS::UseDualStack - UseDualStack *bool - // When true, send this request to the FIPS-compliant regional endpoint. If the // configured endpoint does not have a FIPS compliant endpoint, dispatching the // request will return an error. @@ -254,13 +245,14 @@ type EndpointParameters struct { // AWS::UseFIPS UseFIPS *bool - // Override the endpoint used to send this request + // When true, use the dual-stack endpoint. If the configured endpoint does not + // support dual-stack, dispatching the request MAY return an error. // - // Parameter is - // required. + // Defaults to + // false if no value is provided. // - // SDK::Endpoint - Endpoint *string + // AWS::UseDualStack + UseDualStack *bool } // ValidateRequired validates required parameters are set. @@ -327,30 +319,9 @@ func (r *resolver) ResolveEndpoint( if err = params.ValidateRequired(); err != nil { return endpoint, fmt.Errorf("endpoint parameters are not valid, %w", err) } - _UseDualStack := *params.UseDualStack _UseFIPS := *params.UseFIPS + _UseDualStack := *params.UseDualStack - if exprVal := params.Endpoint; exprVal != nil { - _Endpoint := *exprVal - _ = _Endpoint - if _UseFIPS == true { - return endpoint, fmt.Errorf("endpoint rule error, %s", "Invalid Configuration: FIPS and custom endpoint are not supported") - } - if _UseDualStack == true { - return endpoint, fmt.Errorf("endpoint rule error, %s", "Invalid Configuration: Dualstack and custom endpoint are not supported") - } - uriString := _Endpoint - - uri, err := url.Parse(uriString) - if err != nil { - return endpoint, fmt.Errorf("Failed to parse uri: %s", uriString) - } - - return smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - }, nil - } if exprVal := params.Region; exprVal != nil { _Region := *exprVal _ = _Region @@ -358,60 +329,13 @@ func (r *resolver) ResolveEndpoint( _PartitionResult := *exprVal _ = _PartitionResult if _UseFIPS == true { - if _UseDualStack == true { - if true == _PartitionResult.SupportsFIPS { - if true == _PartitionResult.SupportsDualStack { - uriString := func() string { - var out strings.Builder - out.WriteString("https://api.ecr-public-fips.") - out.WriteString(_Region) - out.WriteString(".") - out.WriteString(_PartitionResult.DualStackDnsSuffix) - return out.String() - }() - - uri, err := url.Parse(uriString) - if err != nil { - return endpoint, fmt.Errorf("Failed to parse uri: %s", uriString) - } - - return smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - }, nil - } - } - return endpoint, fmt.Errorf("endpoint rule error, %s", "FIPS and DualStack are enabled, but this partition does not support one or both") - } - } - if _UseFIPS == true { - if true == _PartitionResult.SupportsFIPS { - uriString := func() string { - var out strings.Builder - out.WriteString("https://api.ecr-public-fips.") - out.WriteString(_Region) - out.WriteString(".") - out.WriteString(_PartitionResult.DnsSuffix) - return out.String() - }() - - uri, err := url.Parse(uriString) - if err != nil { - return endpoint, fmt.Errorf("Failed to parse uri: %s", uriString) - } - - return smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - }, nil - } - return endpoint, fmt.Errorf("endpoint rule error, %s", "FIPS is enabled but this partition does not support FIPS") + return endpoint, fmt.Errorf("endpoint rule error, %s", "ECR Public does not support FIPS") } if _UseDualStack == true { if true == _PartitionResult.SupportsDualStack { uriString := func() string { var out strings.Builder - out.WriteString("https://api.ecr-public.") + out.WriteString("https://ecr-public.") out.WriteString(_Region) out.WriteString(".") out.WriteString(_PartitionResult.DualStackDnsSuffix) @@ -428,7 +352,7 @@ func (r *resolver) ResolveEndpoint( Headers: http.Header{}, }, nil } - return endpoint, fmt.Errorf("endpoint rule error, %s", "DualStack is enabled but this partition does not support DualStack") + return endpoint, fmt.Errorf("endpoint rule error, %s", "Dualstack is enabled but this partition does not support dualstack") } uriString := func() string { var out strings.Builder @@ -449,9 +373,8 @@ func (r *resolver) ResolveEndpoint( Headers: http.Header{}, }, nil } - return endpoint, fmt.Errorf("Endpoint resolution failed. Invalid operation or environment input.") } - return endpoint, fmt.Errorf("endpoint rule error, %s", "Invalid Configuration: Missing Region") + return endpoint, fmt.Errorf("Endpoint resolution failed. Invalid operation or environment input.") } type endpointParamsBinder interface { @@ -462,9 +385,8 @@ func bindEndpointParams(ctx context.Context, input interface{}, options Options) params := &EndpointParameters{} params.Region = bindRegion(options.Region) - params.UseDualStack = aws.Bool(options.EndpointOptions.UseDualStackEndpoint == aws.DualStackEndpointStateEnabled) params.UseFIPS = aws.Bool(options.EndpointOptions.UseFIPSEndpoint == aws.FIPSEndpointStateEnabled) - params.Endpoint = options.BaseEndpoint + params.UseDualStack = aws.Bool(options.EndpointOptions.UseDualStackEndpoint == aws.DualStackEndpointStateEnabled) if b, ok := input.(endpointParamsBinder); ok { b.bindEndpointParams(params) diff --git a/service/ecrpublic/endpoints_test.go b/service/ecrpublic/endpoints_test.go index 2dcaefb30df..58c0ddf4bc5 100644 --- a/service/ecrpublic/endpoints_test.go +++ b/service/ecrpublic/endpoints_test.go @@ -14,476 +14,13 @@ import ( "testing" ) -// For region us-east-1 with FIPS enabled and DualStack enabled +// Valid with dualstack and FIPS disabled. i.e, IPv4 Only stack with no FIPS, with +// special prefix func TestEndpointCase0(t *testing.T) { var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.us-east-1.api.aws") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-east-1 with FIPS enabled and DualStack disabled -func TestEndpointCase1(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.us-east-1.amazonaws.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-east-1 with FIPS disabled and DualStack enabled -func TestEndpointCase2(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.us-east-1.api.aws") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-east-1 with FIPS disabled and DualStack disabled -func TestEndpointCase3(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.us-east-1.amazonaws.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region cn-north-1 with FIPS enabled and DualStack enabled -func TestEndpointCase4(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("cn-north-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.cn-north-1.api.amazonwebservices.com.cn") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region cn-north-1 with FIPS enabled and DualStack disabled -func TestEndpointCase5(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("cn-north-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.cn-north-1.amazonaws.com.cn") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region cn-north-1 with FIPS disabled and DualStack enabled -func TestEndpointCase6(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("cn-north-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.cn-north-1.api.amazonwebservices.com.cn") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region cn-north-1 with FIPS disabled and DualStack disabled -func TestEndpointCase7(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("cn-north-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.cn-north-1.amazonaws.com.cn") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-gov-east-1 with FIPS enabled and DualStack enabled -func TestEndpointCase8(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-gov-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.us-gov-east-1.api.aws") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-gov-east-1 with FIPS enabled and DualStack disabled -func TestEndpointCase9(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-gov-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.us-gov-east-1.amazonaws.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-gov-east-1 with FIPS disabled and DualStack enabled -func TestEndpointCase10(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-gov-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.us-gov-east-1.api.aws") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-gov-east-1 with FIPS disabled and DualStack disabled -func TestEndpointCase11(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-gov-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.us-gov-east-1.amazonaws.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-iso-east-1 with FIPS enabled and DualStack enabled -func TestEndpointCase12(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-iso-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err == nil { - t.Fatalf("expect error, got none") - } - if e, a := "FIPS and DualStack are enabled, but this partition does not support one or both", err.Error(); !strings.Contains(a, e) { - t.Errorf("expect %v error in %v", e, a) - } -} - -// For region us-iso-east-1 with FIPS enabled and DualStack disabled -func TestEndpointCase13(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-iso-east-1"), - UseFIPS: ptr.Bool(true), UseDualStack: ptr.Bool(false), + UseFIPS: ptr.Bool(false), + Region: ptr.String("us-east-1"), } resolver := NewDefaultEndpointResolverV2() @@ -494,7 +31,7 @@ func TestEndpointCase13(t *testing.T) { t.Fatalf("expect no error, got %v", err) } - uri, _ := url.Parse("https://api.ecr-public-fips.us-iso-east-1.c2s.ic.gov") + uri, _ := url.Parse("https://api.ecr-public.us-east-1.amazonaws.com") expectEndpoint := smithyendpoints.Endpoint{ URI: *uri, @@ -515,32 +52,12 @@ func TestEndpointCase13(t *testing.T) { } } -// For region us-iso-east-1 with FIPS disabled and DualStack enabled -func TestEndpointCase14(t *testing.T) { +// Valid with dualstack enabled +func TestEndpointCase1(t *testing.T) { var params = EndpointParameters{ - Region: ptr.String("us-iso-east-1"), - UseFIPS: ptr.Bool(false), UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err == nil { - t.Fatalf("expect error, got none") - } - if e, a := "DualStack is enabled but this partition does not support DualStack", err.Error(); !strings.Contains(a, e) { - t.Errorf("expect %v error in %v", e, a) - } -} - -// For region us-iso-east-1 with FIPS disabled and DualStack disabled -func TestEndpointCase15(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-iso-east-1"), UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), + Region: ptr.String("us-east-1"), } resolver := NewDefaultEndpointResolverV2() @@ -551,7 +68,7 @@ func TestEndpointCase15(t *testing.T) { t.Fatalf("expect no error, got %v", err) } - uri, _ := url.Parse("https://api.ecr-public.us-iso-east-1.c2s.ic.gov") + uri, _ := url.Parse("https://ecr-public.us-east-1.api.aws") expectEndpoint := smithyendpoints.Endpoint{ URI: *uri, @@ -572,12 +89,12 @@ func TestEndpointCase15(t *testing.T) { } } -// For region us-isob-east-1 with FIPS enabled and DualStack enabled -func TestEndpointCase16(t *testing.T) { +// Invalid with FIPS set, dualstack disabled +func TestEndpointCase2(t *testing.T) { var params = EndpointParameters{ - Region: ptr.String("us-isob-east-1"), + UseDualStack: ptr.Bool(false), UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(true), + Region: ptr.String("us-east-1"), } resolver := NewDefaultEndpointResolverV2() @@ -587,187 +104,17 @@ func TestEndpointCase16(t *testing.T) { if err == nil { t.Fatalf("expect error, got none") } - if e, a := "FIPS and DualStack are enabled, but this partition does not support one or both", err.Error(); !strings.Contains(a, e) { + if e, a := "ECR Public does not support FIPS", err.Error(); !strings.Contains(a, e) { t.Errorf("expect %v error in %v", e, a) } } -// For region us-isob-east-1 with FIPS enabled and DualStack disabled -func TestEndpointCase17(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-isob-east-1"), - UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public-fips.us-isob-east-1.sc2s.sgov.gov") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For region us-isob-east-1 with FIPS disabled and DualStack enabled -func TestEndpointCase18(t *testing.T) { +// Invalid with both dualstack and FIPS enabled +func TestEndpointCase3(t *testing.T) { var params = EndpointParameters{ - Region: ptr.String("us-isob-east-1"), - UseFIPS: ptr.Bool(false), UseDualStack: ptr.Bool(true), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err == nil { - t.Fatalf("expect error, got none") - } - if e, a := "DualStack is enabled but this partition does not support DualStack", err.Error(); !strings.Contains(a, e) { - t.Errorf("expect %v error in %v", e, a) - } -} - -// For region us-isob-east-1 with FIPS disabled and DualStack disabled -func TestEndpointCase19(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-isob-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://api.ecr-public.us-isob-east-1.sc2s.sgov.gov") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For custom endpoint with region set and fips disabled and dualstack disabled -func TestEndpointCase20(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - Endpoint: ptr.String("https://example.com"), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://example.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For custom endpoint with region not set and fips disabled and dualstack disabled -func TestEndpointCase21(t *testing.T) { - var params = EndpointParameters{ - UseFIPS: ptr.Bool(false), - UseDualStack: ptr.Bool(false), - Endpoint: ptr.String("https://example.com"), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err != nil { - t.Fatalf("expect no error, got %v", err) - } - - uri, _ := url.Parse("https://example.com") - - expectEndpoint := smithyendpoints.Endpoint{ - URI: *uri, - Headers: http.Header{}, - Properties: smithy.Properties{}, - } - - if e, a := expectEndpoint.URI, result.URI; e != a { - t.Errorf("expect %v URI, got %v", e, a) - } - - if !reflect.DeepEqual(expectEndpoint.Headers, result.Headers) { - t.Errorf("expect headers to match\n%v != %v", expectEndpoint.Headers, result.Headers) - } - - if !reflect.DeepEqual(expectEndpoint.Properties, result.Properties) { - t.Errorf("expect properties to match\n%v != %v", expectEndpoint.Properties, result.Properties) - } -} - -// For custom endpoint with fips enabled and dualstack disabled -func TestEndpointCase22(t *testing.T) { - var params = EndpointParameters{ - Region: ptr.String("us-east-1"), UseFIPS: ptr.Bool(true), - UseDualStack: ptr.Bool(false), - Endpoint: ptr.String("https://example.com"), + Region: ptr.String("us-east-1"), } resolver := NewDefaultEndpointResolverV2() @@ -777,35 +124,17 @@ func TestEndpointCase22(t *testing.T) { if err == nil { t.Fatalf("expect error, got none") } - if e, a := "Invalid Configuration: FIPS and custom endpoint are not supported", err.Error(); !strings.Contains(a, e) { + if e, a := "ECR Public does not support FIPS", err.Error(); !strings.Contains(a, e) { t.Errorf("expect %v error in %v", e, a) } } -// For custom endpoint with fips disabled and dualstack enabled -func TestEndpointCase23(t *testing.T) { +// Invalid with DualStack enabled and partition does not support Dualstack +func TestEndpointCase4(t *testing.T) { var params = EndpointParameters{ - Region: ptr.String("us-east-1"), - UseFIPS: ptr.Bool(false), UseDualStack: ptr.Bool(true), - Endpoint: ptr.String("https://example.com"), - } - - resolver := NewDefaultEndpointResolverV2() - result, err := resolver.ResolveEndpoint(context.Background(), params) - _, _ = result, err - - if err == nil { - t.Fatalf("expect error, got none") - } - if e, a := "Invalid Configuration: Dualstack and custom endpoint are not supported", err.Error(); !strings.Contains(a, e) { - t.Errorf("expect %v error in %v", e, a) + Region: ptr.String("us-isob-east-1"), } -} - -// Missing region -func TestEndpointCase24(t *testing.T) { - var params = EndpointParameters{} resolver := NewDefaultEndpointResolverV2() result, err := resolver.ResolveEndpoint(context.Background(), params) @@ -814,7 +143,7 @@ func TestEndpointCase24(t *testing.T) { if err == nil { t.Fatalf("expect error, got none") } - if e, a := "Invalid Configuration: Missing Region", err.Error(); !strings.Contains(a, e) { + if e, a := "Dualstack is enabled but this partition does not support dualstack", err.Error(); !strings.Contains(a, e) { t.Errorf("expect %v error in %v", e, a) } } diff --git a/service/eks/api_op_DescribeClusterVersions.go b/service/eks/api_op_DescribeClusterVersions.go new file mode 100644 index 00000000000..b14e5314d5e --- /dev/null +++ b/service/eks/api_op_DescribeClusterVersions.go @@ -0,0 +1,268 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package eks + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/service/eks/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Lists available Kubernetes versions for Amazon EKS clusters. +func (c *Client) DescribeClusterVersions(ctx context.Context, params *DescribeClusterVersionsInput, optFns ...func(*Options)) (*DescribeClusterVersionsOutput, error) { + if params == nil { + params = &DescribeClusterVersionsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DescribeClusterVersions", params, optFns, c.addOperationDescribeClusterVersionsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DescribeClusterVersionsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DescribeClusterVersionsInput struct { + + // The type of cluster to filter versions by. + ClusterType *string + + // List of specific cluster versions to describe. + ClusterVersions []string + + // Filter to show only default versions. + DefaultOnly *bool + + // Include all available versions in the response. + IncludeAll *bool + + // Maximum number of results to return. + MaxResults *int32 + + // Pagination token for the next set of results. + NextToken *string + + // Filter versions by their current status. + Status types.ClusterVersionStatus + + noSmithyDocumentSerde +} + +type DescribeClusterVersionsOutput struct { + + // List of cluster version information objects. + ClusterVersions []types.ClusterVersionInformation + + // Pagination token for the next set of results. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDescribeClusterVersionsMiddlewares(stack *middleware.Stack, options Options) (err error) { + if err := stack.Serialize.Add(&setOperationInputMiddleware{}, middleware.After); err != nil { + return err + } + err = stack.Serialize.Add(&awsRestjson1_serializeOpDescribeClusterVersions{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpDescribeClusterVersions{}, middleware.After) + if err != nil { + return err + } + if err := addProtocolFinalizerMiddlewares(stack, options, "DescribeClusterVersions"); err != nil { + return fmt.Errorf("add protocol finalizers: %v", err) + } + + if err = addlegacyEndpointContextSetter(stack, options); err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = addClientRequestID(stack); err != nil { + return err + } + if err = addComputeContentLength(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = addComputePayloadSHA256(stack); err != nil { + return err + } + if err = addRetry(stack, options); err != nil { + return err + } + if err = addRawResponseToMetadata(stack); err != nil { + return err + } + if err = addRecordResponseTiming(stack); err != nil { + return err + } + if err = addSpanRetryLoop(stack, options); err != nil { + return err + } + if err = addClientUserAgent(stack, options); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addSetLegacyContextSigningOptionsMiddleware(stack); err != nil { + return err + } + if err = addTimeOffsetBuild(stack, c); err != nil { + return err + } + if err = addUserAgentRetryMode(stack, options); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeClusterVersions(options.Region), middleware.Before); err != nil { + return err + } + if err = addRecursionDetection(stack); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + if err = addDisableHTTPSMiddleware(stack, options); err != nil { + return err + } + if err = addSpanInitializeStart(stack); err != nil { + return err + } + if err = addSpanInitializeEnd(stack); err != nil { + return err + } + if err = addSpanBuildRequestStart(stack); err != nil { + return err + } + if err = addSpanBuildRequestEnd(stack); err != nil { + return err + } + return nil +} + +// DescribeClusterVersionsPaginatorOptions is the paginator options for +// DescribeClusterVersions +type DescribeClusterVersionsPaginatorOptions struct { + // Maximum number of results to return. + 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 +} + +// DescribeClusterVersionsPaginator is a paginator for DescribeClusterVersions +type DescribeClusterVersionsPaginator struct { + options DescribeClusterVersionsPaginatorOptions + client DescribeClusterVersionsAPIClient + params *DescribeClusterVersionsInput + nextToken *string + firstPage bool +} + +// NewDescribeClusterVersionsPaginator returns a new +// DescribeClusterVersionsPaginator +func NewDescribeClusterVersionsPaginator(client DescribeClusterVersionsAPIClient, params *DescribeClusterVersionsInput, optFns ...func(*DescribeClusterVersionsPaginatorOptions)) *DescribeClusterVersionsPaginator { + if params == nil { + params = &DescribeClusterVersionsInput{} + } + + options := DescribeClusterVersionsPaginatorOptions{} + if params.MaxResults != nil { + options.Limit = *params.MaxResults + } + + for _, fn := range optFns { + fn(&options) + } + + return &DescribeClusterVersionsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *DescribeClusterVersionsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next DescribeClusterVersions page. +func (p *DescribeClusterVersionsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeClusterVersionsOutput, 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.MaxResults = limit + + optFns = append([]func(*Options){ + addIsPaginatorUserAgent, + }, optFns...) + result, err := p.client.DescribeClusterVersions(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 +} + +// DescribeClusterVersionsAPIClient is a client that implements the +// DescribeClusterVersions operation. +type DescribeClusterVersionsAPIClient interface { + DescribeClusterVersions(context.Context, *DescribeClusterVersionsInput, ...func(*Options)) (*DescribeClusterVersionsOutput, error) +} + +var _ DescribeClusterVersionsAPIClient = (*Client)(nil) + +func newServiceMetadataMiddleware_opDescribeClusterVersions(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + OperationName: "DescribeClusterVersions", + } +} diff --git a/service/eks/deserializers.go b/service/eks/deserializers.go index 7fec3e2bed1..8c88fa242f9 100644 --- a/service/eks/deserializers.go +++ b/service/eks/deserializers.go @@ -3793,6 +3793,173 @@ func awsRestjson1_deserializeOpDocumentDescribeClusterOutput(v **DescribeCluster return nil } +type awsRestjson1_deserializeOpDescribeClusterVersions struct { +} + +func (*awsRestjson1_deserializeOpDescribeClusterVersions) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpDescribeClusterVersions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + _, span := tracing.StartSpan(ctx, "OperationDeserializer") + endTimer := startMetricTimer(ctx, "client.call.deserialization_duration") + defer endTimer() + defer span.End() + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorDescribeClusterVersions(response, &metadata) + } + output := &DescribeClusterVersionsOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsRestjson1_deserializeOpDocumentDescribeClusterVersionsOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + span.End() + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorDescribeClusterVersions(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + headerCode := response.Header.Get("X-Amzn-ErrorType") + if len(headerCode) != 0 { + errorCode = restjson.SanitizeErrorCode(headerCode) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + jsonCode, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(headerCode) == 0 && len(jsonCode) != 0 { + errorCode = restjson.SanitizeErrorCode(jsonCode) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsRestjson1_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ServerException", errorCode): + return awsRestjson1_deserializeErrorServerException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentDescribeClusterVersionsOutput(v **DescribeClusterVersionsOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *DescribeClusterVersionsOutput + if *v == nil { + sv = &DescribeClusterVersionsOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "clusterVersions": + if err := awsRestjson1_deserializeDocumentClusterVersionList(&sv.ClusterVersions, value); err != nil { + return err + } + + case "nextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + type awsRestjson1_deserializeOpDescribeEksAnywhereSubscription struct { } @@ -11392,6 +11559,173 @@ func awsRestjson1_deserializeDocumentClusterIssueList(v *[]types.ClusterIssue, v return nil } +func awsRestjson1_deserializeDocumentClusterVersionInformation(v **types.ClusterVersionInformation, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ClusterVersionInformation + if *v == nil { + sv = &types.ClusterVersionInformation{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "clusterType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.ClusterType = ptr.String(jtv) + } + + case "clusterVersion": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.ClusterVersion = ptr.String(jtv) + } + + case "defaultPlatformVersion": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.DefaultPlatformVersion = ptr.String(jtv) + } + + case "defaultVersion": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.DefaultVersion = jtv + } + + case "endOfExtendedSupportDate": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.EndOfExtendedSupportDate = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "endOfStandardSupportDate": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.EndOfStandardSupportDate = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "kubernetesPatchVersion": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.KubernetesPatchVersion = ptr.String(jtv) + } + + case "releaseDate": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.ReleaseDate = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "status": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ClusterVersionStatus to be of type string, got %T instead", value) + } + sv.Status = types.ClusterVersionStatus(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentClusterVersionList(v *[]types.ClusterVersionInformation, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ClusterVersionInformation + if *v == nil { + cv = []types.ClusterVersionInformation{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ClusterVersionInformation + destAddr := &col + if err := awsRestjson1_deserializeDocumentClusterVersionInformation(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentCompatibilities(v *[]types.Compatibility, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/eks/generated.json b/service/eks/generated.json index 5dc0c284508..1f6bb96e4dc 100644 --- a/service/eks/generated.json +++ b/service/eks/generated.json @@ -32,6 +32,7 @@ "api_op_DescribeAddonConfiguration.go", "api_op_DescribeAddonVersions.go", "api_op_DescribeCluster.go", + "api_op_DescribeClusterVersions.go", "api_op_DescribeEksAnywhereSubscription.go", "api_op_DescribeFargateProfile.go", "api_op_DescribeIdentityProviderConfig.go", diff --git a/service/eks/serializers.go b/service/eks/serializers.go index cfcf16c42a2..80344615bd8 100644 --- a/service/eks/serializers.go +++ b/service/eks/serializers.go @@ -2344,6 +2344,98 @@ func awsRestjson1_serializeOpHttpBindingsDescribeClusterInput(v *DescribeCluster return nil } +type awsRestjson1_serializeOpDescribeClusterVersions struct { +} + +func (*awsRestjson1_serializeOpDescribeClusterVersions) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpDescribeClusterVersions) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + _, span := tracing.StartSpan(ctx, "OperationSerializer") + endTimer := startMetricTimer(ctx, "client.call.serialization_duration") + defer endTimer() + defer span.End() + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DescribeClusterVersionsInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/cluster-versions") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "GET" + var restEncoder *httpbinding.Encoder + if request.URL.RawPath == "" { + restEncoder, err = httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + } else { + request.URL.RawPath = smithyhttp.JoinPath(request.URL.RawPath, opPath) + restEncoder, err = httpbinding.NewEncoderWithRawPath(request.URL.Path, request.URL.RawPath, request.URL.RawQuery, request.Header) + } + + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsDescribeClusterVersionsInput(input, restEncoder); 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} + } + in.Request = request + + endTimer() + span.End() + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsDescribeClusterVersionsInput(v *DescribeClusterVersionsInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.ClusterType != nil { + encoder.SetQuery("clusterType").String(*v.ClusterType) + } + + if v.ClusterVersions != nil { + for i := range v.ClusterVersions { + encoder.AddQuery("clusterVersions").String(v.ClusterVersions[i]) + } + } + + if v.DefaultOnly != nil { + encoder.SetQuery("defaultOnly").Boolean(*v.DefaultOnly) + } + + if v.IncludeAll != nil { + encoder.SetQuery("includeAll").Boolean(*v.IncludeAll) + } + + if v.MaxResults != nil { + encoder.SetQuery("maxResults").Integer(*v.MaxResults) + } + + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) + } + + if len(v.Status) > 0 { + encoder.SetQuery("status").String(string(v.Status)) + } + + return nil +} + type awsRestjson1_serializeOpDescribeEksAnywhereSubscription struct { } diff --git a/service/eks/snapshot/api_op_DescribeClusterVersions.go.snap b/service/eks/snapshot/api_op_DescribeClusterVersions.go.snap new file mode 100644 index 00000000000..15e696f05f2 --- /dev/null +++ b/service/eks/snapshot/api_op_DescribeClusterVersions.go.snap @@ -0,0 +1,40 @@ +DescribeClusterVersions + Initialize stack step + spanInitializeStart + RegisterServiceMetadata + legacyEndpointContextSetter + SetLogger + spanInitializeEnd + Serialize stack step + spanBuildRequestStart + setOperationInput + ResolveEndpoint + OperationSerializer + Build stack step + ClientRequestID + ComputeContentLength + UserAgent + AddTimeOffsetMiddleware + RecursionDetection + spanBuildRequestEnd + Finalize stack step + ResolveAuthScheme + GetIdentity + ResolveEndpointV2 + disableHTTPS + ComputePayloadHash + spanRetryLoop + Retry + RetryMetricsHeader + setLegacyContextSigningOptions + Signing + Deserialize stack step + AddRawResponseToMetadata + ErrorCloseResponseBody + CloseResponseBody + ResponseErrorWrapper + RequestIDRetriever + OperationDeserializer + AddTimeOffsetMiddleware + RecordResponseTiming + RequestResponseLogger diff --git a/service/eks/snapshot_test.go b/service/eks/snapshot_test.go index 41734629bb5..d2a42061c12 100644 --- a/service/eks/snapshot_test.go +++ b/service/eks/snapshot_test.go @@ -338,6 +338,18 @@ func TestCheckSnapshot_DescribeCluster(t *testing.T) { } } +func TestCheckSnapshot_DescribeClusterVersions(t *testing.T) { + svc := New(Options{}) + _, err := svc.DescribeClusterVersions(context.Background(), nil, func(o *Options) { + o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error { + return testSnapshot(stack, "DescribeClusterVersions") + }) + }) + if _, ok := err.(snapshotOK); !ok && err != nil { + t.Fatal(err) + } +} + func TestCheckSnapshot_DescribeEksAnywhereSubscription(t *testing.T) { svc := New(Options{}) _, err := svc.DescribeEksAnywhereSubscription(context.Background(), nil, func(o *Options) { @@ -1009,6 +1021,18 @@ func TestUpdateSnapshot_DescribeCluster(t *testing.T) { } } +func TestUpdateSnapshot_DescribeClusterVersions(t *testing.T) { + svc := New(Options{}) + _, err := svc.DescribeClusterVersions(context.Background(), nil, func(o *Options) { + o.APIOptions = append(o.APIOptions, func(stack *middleware.Stack) error { + return updateSnapshot(stack, "DescribeClusterVersions") + }) + }) + if _, ok := err.(snapshotOK); !ok && err != nil { + t.Fatal(err) + } +} + func TestUpdateSnapshot_DescribeEksAnywhereSubscription(t *testing.T) { svc := New(Options{}) _, err := svc.DescribeEksAnywhereSubscription(context.Background(), nil, func(o *Options) { diff --git a/service/eks/types/enums.go b/service/eks/types/enums.go index 83a3903a0a0..af84b0634e7 100644 --- a/service/eks/types/enums.go +++ b/service/eks/types/enums.go @@ -273,6 +273,27 @@ func (ClusterStatus) Values() []ClusterStatus { } } +type ClusterVersionStatus string + +// Enum values for ClusterVersionStatus +const ( + ClusterVersionStatusUnsupported ClusterVersionStatus = "unsupported" + ClusterVersionStatusStandardSupport ClusterVersionStatus = "standard-support" + ClusterVersionStatusExtendedSupport ClusterVersionStatus = "extended-support" +) + +// Values returns all known values for ClusterVersionStatus. 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 (ClusterVersionStatus) Values() []ClusterVersionStatus { + return []ClusterVersionStatus{ + "unsupported", + "standard-support", + "extended-support", + } +} + type ConfigStatus string // Enum values for ConfigStatus diff --git a/service/eks/types/types.go b/service/eks/types/types.go index f1e270c7124..eef31f69715 100644 --- a/service/eks/types/types.go +++ b/service/eks/types/types.go @@ -167,12 +167,10 @@ type Addon struct { noSmithyDocumentSerde } -// The summary information about the Amazon EKS add-on compatibility for the next -// Kubernetes version for an insight check in the UPGRADE_READINESS category. +// Contains compatibility information for an Amazon EKS add-on. type AddonCompatibilityDetail struct { - // The list of compatible Amazon EKS add-on versions for the next Kubernetes - // version. + // A list of compatible add-on versions. CompatibleVersions []string // The name of the Amazon EKS add-on. @@ -500,6 +498,39 @@ type ClusterIssue struct { noSmithyDocumentSerde } +// Contains details about a specific EKS cluster version. +type ClusterVersionInformation struct { + + // The type of cluster this version is for. + ClusterType *string + + // The Kubernetes version for the cluster. + ClusterVersion *string + + // Default platform version for this Kubernetes version. + DefaultPlatformVersion *string + + // Indicates if this is a default version. + DefaultVersion bool + + // Date when extended support ends for this version. + EndOfExtendedSupportDate *time.Time + + // Date when standard support ends for this version. + EndOfStandardSupportDate *time.Time + + // The patch version of Kubernetes for this cluster version. + KubernetesPatchVersion *string + + // The release date of this cluster version. + ReleaseDate *time.Time + + // Current status of this cluster version. + Status ClusterVersionStatus + + noSmithyDocumentSerde +} + // Compatibility information. type Compatibility struct { diff --git a/service/glue/api_op_GetCatalogs.go b/service/glue/api_op_GetCatalogs.go index 9fd985b3f27..6e11a047bb4 100644 --- a/service/glue/api_op_GetCatalogs.go +++ b/service/glue/api_op_GetCatalogs.go @@ -31,6 +31,14 @@ func (c *Client) GetCatalogs(ctx context.Context, params *GetCatalogsInput, optF type GetCatalogsInput struct { + // Whether to list the default catalog in the account and region in the response. + // Defaults to false . When true and ParentCatalogId = NULL | Amazon Web Services + // Account ID , all catalogs and the default catalog are enumerated in the response. + // + // When the ParentCatalogId is not equal to null, and this attribute is passed as + // false or true , an InvalidInputException is thrown. + IncludeRoot *bool + // The maximum number of catalogs to return in one response. MaxResults *int32 @@ -41,8 +49,9 @@ type GetCatalogsInput struct { // the Amazon Web Services Account Number is used by default. ParentCatalogId *string - // When specified as true, iterates through the account and returns all catalog - // resources (including top-level resources and child resources) + // Whether to list all catalogs across the catalog hierarchy, starting from the + // ParentCatalogId . Defaults to false . When true , all catalog objects in the + // ParentCatalogID hierarchy are enumerated in the response. Recursive bool noSmithyDocumentSerde diff --git a/service/glue/api_op_StartJobRun.go b/service/glue/api_op_StartJobRun.go index eb1257e2d3b..d0dbdddb5f6 100644 --- a/service/glue/api_op_StartJobRun.go +++ b/service/glue/api_op_StartJobRun.go @@ -130,10 +130,14 @@ type StartJobRunInput struct { // consume resources before it is terminated and enters TIMEOUT status. This value // overrides the timeout value set in the parent job. // - // Streaming jobs must have timeout values less than 7 days or 10080 minutes. When - // the value is left blank, the job will be restarted after 7 days based if you - // have not setup a maintenance window. If you have setup maintenance window, it - // will be restarted during the maintenance window after 7 days. + // Jobs must have timeout values less than 7 days or 10080 minutes. Otherwise, the + // jobs will throw an exception. + // + // When the value is left blank, the timeout is defaulted to 2880 minutes. + // + // Any existing Glue jobs that had a timeout value greater than 7 days will be + // defaulted to 7 days. For instance if you have specified a timeout of 20 days for + // a batch job, it will be stopped on the 7th day. Timeout *int32 // The type of predefined worker that is allocated when a job runs. Accepts a diff --git a/service/glue/internal/endpoints/endpoints.go b/service/glue/internal/endpoints/endpoints.go index f161e7af175..17a88872060 100644 --- a/service/glue/internal/endpoints/endpoints.go +++ b/service/glue/internal/endpoints/endpoints.go @@ -142,69 +142,201 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "af-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "af-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.af-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-northeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-northeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-northeast-3.api.aws", + }, endpoints.EndpointKey{ Region: "ap-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-south-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-south-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-south-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-southeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-southeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-southeast-3.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-4", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-4", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-southeast-4.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-5", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-5", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ap-southeast-5.api.aws", + }, endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ca-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "ca-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.ca-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-central-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-central-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-central-2.api.aws", + }, endpoints.EndpointKey{ Region: "eu-north-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-north-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-north-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-south-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-south-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-south-2.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-west-2.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.eu-west-3.api.aws", + }, endpoints.EndpointKey{ Region: "fips-us-east-1", }: endpoints.Endpoint{ @@ -244,15 +376,39 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "il-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "il-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.il-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "me-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.me-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.me-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "sa-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "sa-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.sa-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, @@ -262,6 +418,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "glue-fips.us-east-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "glue-fips.us-east-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.us-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, @@ -271,6 +439,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "glue-fips.us-east-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "glue-fips.us-east-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.us-east-2.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, @@ -280,6 +460,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "glue-fips.us-west-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "glue-fips.us-west-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.us-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, @@ -289,6 +481,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "glue-fips.us-west-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "glue-fips.us-west-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.us-west-2.api.aws", + }, }, }, { @@ -329,9 +533,21 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "cn-north-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "cn-north-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.cn-north-1.api.amazonwebservices.com.cn", + }, endpoints.EndpointKey{ Region: "cn-northwest-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "cn-northwest-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "glue.cn-northwest-1.api.amazonwebservices.com.cn", + }, }, }, { diff --git a/service/glue/serializers.go b/service/glue/serializers.go index c5759eda79f..b7b64b63ef8 100644 --- a/service/glue/serializers.go +++ b/service/glue/serializers.go @@ -27798,6 +27798,11 @@ func awsAwsjson11_serializeOpDocumentGetCatalogsInput(v *GetCatalogsInput, value object := value.Object() defer object.Close() + if v.IncludeRoot != nil { + ok := object.Key("IncludeRoot") + ok.Boolean(*v.IncludeRoot) + } + if v.MaxResults != nil { ok := object.Key("MaxResults") ok.Integer(*v.MaxResults) diff --git a/service/glue/types/types.go b/service/glue/types/types.go index 6b985a0bd66..9bd37dc61c1 100644 --- a/service/glue/types/types.go +++ b/service/glue/types/types.go @@ -5723,10 +5723,14 @@ type JobRun struct { // consume resources before it is terminated and enters TIMEOUT status. This value // overrides the timeout value set in the parent job. // - // Streaming jobs must have timeout values less than 7 days or 10080 minutes. When - // the value is left blank, the job will be restarted after 7 days based if you - // have not setup a maintenance window. If you have setup maintenance window, it - // will be restarted during the maintenance window after 7 days. + // Jobs must have timeout values less than 7 days or 10080 minutes. Otherwise, the + // jobs will throw an exception. + // + // When the value is left blank, the timeout is defaulted to 2880 minutes. + // + // Any existing Glue jobs that had a timeout value greater than 7 days will be + // defaulted to 7 days. For instance if you have specified a timeout of 20 days for + // a batch job, it will be stopped on the 7th day. Timeout *int32 // The name of the trigger that started this job run. diff --git a/service/macie2/internal/endpoints/endpoints.go b/service/macie2/internal/endpoints/endpoints.go index 348097b4a24..7c9a2f78524 100644 --- a/service/macie2/internal/endpoints/endpoints.go +++ b/service/macie2/internal/endpoints/endpoints.go @@ -142,48 +142,138 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "af-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "af-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.af-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-northeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-northeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-northeast-3.api.aws", + }, endpoints.EndpointKey{ Region: "ap-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-southeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ap-southeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.ca-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-north-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-north-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-north-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-west-2.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.eu-west-3.api.aws", + }, endpoints.EndpointKey{ Region: "fips-us-east-1", }: endpoints.Endpoint{ @@ -223,12 +313,30 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "il-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "il-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.il-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.me-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "sa-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "sa-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.sa-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, @@ -238,6 +346,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "macie2-fips.us-east-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "macie2-fips.us-east-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.us-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, @@ -247,6 +367,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "macie2-fips.us-east-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "macie2-fips.us-east-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.us-east-2.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, @@ -256,6 +388,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "macie2-fips.us-west-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "macie2-fips.us-west-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.us-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, @@ -265,6 +409,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "macie2-fips.us-west-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "macie2-fips.us-west-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "macie2.us-west-2.api.aws", + }, }, }, { diff --git a/service/mediaconvert/internal/endpoints/endpoints.go b/service/mediaconvert/internal/endpoints/endpoints.go index f7915d2229e..8adeb651774 100644 --- a/service/mediaconvert/internal/endpoints/endpoints.go +++ b/service/mediaconvert/internal/endpoints/endpoints.go @@ -142,27 +142,75 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "af-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "af-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.af-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-northeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-northeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-northeast-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-northeast-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-northeast-3.api.aws", + }, endpoints.EndpointKey{ Region: "ap-south-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-south-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-south-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-southeast-1.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-southeast-2.api.aws", + }, endpoints.EndpointKey{ Region: "ap-southeast-4", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-4", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ap-southeast-4.api.aws", + }, endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, @@ -172,21 +220,63 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert-fips.ca-central-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert-fips.ca-central-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.ca-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.eu-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-north-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-north-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.eu-north-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.eu-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.eu-west-2.api.aws", + }, endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "eu-west-3", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.eu-west-3.api.aws", + }, endpoints.EndpointKey{ Region: "fips-ca-central-1", }: endpoints.Endpoint{ @@ -235,9 +325,21 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "me-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.me-central-1.api.aws", + }, endpoints.EndpointKey{ Region: "sa-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "sa-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.sa-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, @@ -247,6 +349,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert-fips.us-east-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert-fips.us-east-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-east-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, @@ -256,6 +370,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert-fips.us-east-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert-fips.us-east-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-east-2.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, @@ -265,6 +391,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert-fips.us-west-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert-fips.us-west-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-west-1.api.aws", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, @@ -274,6 +412,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert-fips.us-west-2.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert-fips.us-west-2.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-west-2.api.aws", + }, }, }, { @@ -313,11 +463,12 @@ var defaultPartitions = endpoints.Partitions{ Endpoints: endpoints.Endpoints{ endpoints.EndpointKey{ Region: "cn-northwest-1", - }: endpoints.Endpoint{ - Hostname: "mediaconvert.cn-northwest-1.amazonaws.com.cn", - CredentialScope: endpoints.CredentialScope{ - Region: "cn-northwest-1", - }, + }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "cn-northwest-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.cn-northwest-1.api.amazonwebservices.com.cn", }, }, }, @@ -458,6 +609,18 @@ var defaultPartitions = endpoints.Partitions{ }: { Hostname: "mediaconvert.us-gov-west-1.amazonaws.com", }, + endpoints.EndpointKey{ + Region: "us-gov-west-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-gov-west-1.api.aws", + }, + endpoints.EndpointKey{ + Region: "us-gov-west-1", + Variant: endpoints.FIPSVariant | endpoints.DualStackVariant, + }: { + Hostname: "mediaconvert.us-gov-west-1.api.aws", + }, }, }, }