From 269aeed752d6f2df45269bc80a31abb235057740 Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 10:42:46 -0700 Subject: [PATCH 1/6] fix route53 customization --- .../aws/go/codegen/customization/Route53Customizations.java | 2 +- service/route53/internal/customizations/sanitizeurl_test.go | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java index 9af6f232932..c02839a9adc 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java @@ -110,7 +110,7 @@ private void writeHostedZoneIDInputSanitizer( writer.addUseImports(SmithyGoDependency.STRINGS); for (MemberShape member : hostedZoneIDMembers) { writer.openBlock("if i.$L != nil {", "}", member.getMemberName(), () -> { - writer.write("values := strings.SplitN(*i.$L, \"/\", 2)", member.getMemberName()); + writer.write("values := strings.Split(*i.$L, \"/\")", member.getMemberName()); writer.write("v := values[len(values)-1]"); writer.write("i.$L = &v", member.getMemberName()); }); diff --git a/service/route53/internal/customizations/sanitizeurl_test.go b/service/route53/internal/customizations/sanitizeurl_test.go index 0496af9f92c..aa413ac710a 100644 --- a/service/route53/internal/customizations/sanitizeurl_test.go +++ b/service/route53/internal/customizations/sanitizeurl_test.go @@ -27,6 +27,10 @@ func TestSanitizeURLMiddleware(t *testing.T) { Given: "ABCDEFG", ExpectedURL: "https://route53.amazonaws.com/2013-04-01/delegationset/ABCDEFG", }, + "includes leading / in hostedzone": { + Given: "/hostedzone/ABCDEFG", + ExpectedURL: "https://route53.amazonaws.com/2013-04-01/delegationset/ABCDEFG", + }, } for name, c := range cases { From 883c13b4b7a82c9fbae91f5a8d91721afe907e59 Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 11:40:31 -0700 Subject: [PATCH 2/6] fix s3shared mod dep --- .../aws/go/codegen/customization/AwsCustomGoDependency.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/AwsCustomGoDependency.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/AwsCustomGoDependency.java index 8568fa7f806..3937215f728 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/AwsCustomGoDependency.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/AwsCustomGoDependency.java @@ -47,7 +47,7 @@ private AwsCustomGoDependency() { } private static final class Versions { - private static final String INTERNAL_S3SHARED = "v0.26.1-0.20201016111247-66b2791dafc4"; + private static final String INTERNAL_S3SHARED = "v0.2.1-0.20201019214249-1049b73d5c17"; private static final String INTERNAL_ACCEPTENCODING = "v0.0.0-20200930084954-897dfb99530c"; private static final String INTERNAL_PRESIGNURL = "v0.0.0-20201020212433-5fb7a9ec04bb"; } From f0bf60257f9911e12669a52e14198bb0efcc6070 Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 11:53:51 -0700 Subject: [PATCH 3/6] update sdk hash --- .../software/amazon/smithy/aws/go/codegen/AwsGoDependency.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java index 5d0315b52f7..96a90867410 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java @@ -82,6 +82,6 @@ protected static GoDependency module( } private static final class Versions { - private static final String AWS_SDK = "v0.27.1-0.20201020212433-5fb7a9ec04bb"; + private static final String AWS_SDK = "v0.27.1-0.20201021184031-883c13b4b7a8"; } } From 67681f0c13834bc27757d1bf0fb668d5403a69bc Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 12:37:10 -0700 Subject: [PATCH 4/6] generated route53 client --- service/route53/api_client.go | 150 +++++++++++++++++----------------- service/route53/go.mod | 2 +- 2 files changed, 76 insertions(+), 76 deletions(-) diff --git a/service/route53/api_client.go b/service/route53/api_client.go index 8a5ede64102..48d72be7f3d 100644 --- a/service/route53/api_client.go +++ b/service/route53/api_client.go @@ -205,188 +205,188 @@ func addSanitizeURLMiddleware(stack *middleware.Stack) { // another operation (e.g. it expects just '1234') func sanitizeHostedZoneIDInput(input interface{}) error { switch i := input.(type) { - case *ChangeResourceRecordSetsInput: + case *AssociateVPCWithHostedZoneInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *DeleteReusableDelegationSetInput: - if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + case *ChangeResourceRecordSetsInput: + if i.HostedZoneId != nil { + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] - i.Id = &v + i.HostedZoneId = &v } - case *ListHostedZonesInput: + case *CreateHostedZoneInput: if i.DelegationSetId != nil { - values := strings.SplitN(*i.DelegationSetId, "/", 2) + values := strings.Split(*i.DelegationSetId, "/") v := values[len(values)-1] i.DelegationSetId = &v } case *CreateQueryLoggingConfigInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *ListResourceRecordSetsInput: + case *CreateReusableDelegationSetInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *GetReusableDelegationSetInput: - if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + case *CreateTrafficPolicyInstanceInput: + if i.HostedZoneId != nil { + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] - i.Id = &v + i.HostedZoneId = &v } - case *GetHostedZoneInput: + case *CreateVPCAssociationAuthorizationInput: + if i.HostedZoneId != nil { + values := strings.Split(*i.HostedZoneId, "/") + v := values[len(values)-1] + i.HostedZoneId = &v + } + + case *DeleteHostedZoneInput: if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + values := strings.Split(*i.Id, "/") v := values[len(values)-1] i.Id = &v } - case *ListTrafficPolicyInstancesByPolicyInput: - if i.HostedZoneIdMarker != nil { - values := strings.SplitN(*i.HostedZoneIdMarker, "/", 2) + case *DeleteReusableDelegationSetInput: + if i.Id != nil { + values := strings.Split(*i.Id, "/") v := values[len(values)-1] - i.HostedZoneIdMarker = &v + i.Id = &v } - case *CreateVPCAssociationAuthorizationInput: + case *DeleteVPCAssociationAuthorizationInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *CreateTrafficPolicyInstanceInput: + case *DisassociateVPCFromHostedZoneInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *GetReusableDelegationSetLimitInput: - if i.DelegationSetId != nil { - values := strings.SplitN(*i.DelegationSetId, "/", 2) + case *GetChangeInput: + if i.Id != nil { + values := strings.Split(*i.Id, "/") v := values[len(values)-1] - i.DelegationSetId = &v + i.Id = &v } - case *DisassociateVPCFromHostedZoneInput: + case *GetHostedZoneInput: + if i.Id != nil { + values := strings.Split(*i.Id, "/") + v := values[len(values)-1] + i.Id = &v + } + + case *GetHostedZoneLimitInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *ListTrafficPolicyInstancesInput: - if i.HostedZoneIdMarker != nil { - values := strings.SplitN(*i.HostedZoneIdMarker, "/", 2) + case *GetReusableDelegationSetInput: + if i.Id != nil { + values := strings.Split(*i.Id, "/") v := values[len(values)-1] - i.HostedZoneIdMarker = &v + i.Id = &v } - case *CreateHostedZoneInput: + case *GetReusableDelegationSetLimitInput: if i.DelegationSetId != nil { - values := strings.SplitN(*i.DelegationSetId, "/", 2) + values := strings.Split(*i.DelegationSetId, "/") v := values[len(values)-1] i.DelegationSetId = &v } - case *UpdateHostedZoneCommentInput: - if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + case *ListHostedZonesInput: + if i.DelegationSetId != nil { + values := strings.Split(*i.DelegationSetId, "/") v := values[len(values)-1] - i.Id = &v + i.DelegationSetId = &v } - case *GetHostedZoneLimitInput: + case *ListHostedZonesByNameInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *ListHostedZonesByNameInput: + case *ListQueryLoggingConfigsInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *TestDNSAnswerInput: + case *ListResourceRecordSetsInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *ListQueryLoggingConfigsInput: - if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + case *ListTrafficPolicyInstancesInput: + if i.HostedZoneIdMarker != nil { + values := strings.Split(*i.HostedZoneIdMarker, "/") v := values[len(values)-1] - i.HostedZoneId = &v + i.HostedZoneIdMarker = &v } case *ListTrafficPolicyInstancesByHostedZoneInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *GetChangeInput: - if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + case *ListTrafficPolicyInstancesByPolicyInput: + if i.HostedZoneIdMarker != nil { + values := strings.Split(*i.HostedZoneIdMarker, "/") v := values[len(values)-1] - i.Id = &v + i.HostedZoneIdMarker = &v } case *ListVPCAssociationAuthorizationsInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *CreateReusableDelegationSetInput: + case *TestDNSAnswerInput: if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) + values := strings.Split(*i.HostedZoneId, "/") v := values[len(values)-1] i.HostedZoneId = &v } - case *DeleteHostedZoneInput: + case *UpdateHostedZoneCommentInput: if i.Id != nil { - values := strings.SplitN(*i.Id, "/", 2) + values := strings.Split(*i.Id, "/") v := values[len(values)-1] i.Id = &v } - case *DeleteVPCAssociationAuthorizationInput: - if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) - v := values[len(values)-1] - i.HostedZoneId = &v - } - - case *AssociateVPCWithHostedZoneInput: - if i.HostedZoneId != nil { - values := strings.SplitN(*i.HostedZoneId, "/", 2) - v := values[len(values)-1] - i.HostedZoneId = &v - } - default: break } diff --git a/service/route53/go.mod b/service/route53/go.mod index 415f796cc18..73b6e3c26b0 100644 --- a/service/route53/go.mod +++ b/service/route53/go.mod @@ -3,7 +3,7 @@ module github.com/aws/aws-sdk-go-v2/service/route53 go 1.15 require ( - github.com/aws/aws-sdk-go-v2 v0.27.0 + github.com/aws/aws-sdk-go-v2 v0.27.1-0.20201021184031-883c13b4b7a8 github.com/awslabs/smithy-go v0.2.0 ) From ffda7ace423e1f4b091b16cbd2a8faa9f595e56d Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 14:08:57 -0700 Subject: [PATCH 5/6] feedback --- .../customization/Route53Customizations.java | 9 +- service/route53/api_client.go | 104 +++++++++--------- 2 files changed, 57 insertions(+), 56 deletions(-) diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java index c02839a9adc..e59ccbe0cf4 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/customization/Route53Customizations.java @@ -109,10 +109,11 @@ private void writeHostedZoneIDInputSanitizer( writer.openBlock("case $P :", "", symbolProvider.toSymbol(input), () -> { writer.addUseImports(SmithyGoDependency.STRINGS); for (MemberShape member : hostedZoneIDMembers) { - writer.openBlock("if i.$L != nil {", "}", member.getMemberName(), () -> { - writer.write("values := strings.Split(*i.$L, \"/\")", member.getMemberName()); - writer.write("v := values[len(values)-1]"); - writer.write("i.$L = &v", member.getMemberName()); + String memberName = member.getMemberName(); + writer.openBlock("if i.$L != nil {", "}", memberName, () -> { + writer.write("idx := strings.LastIndex(*i.$L, `/`)", memberName); + writer.write("v := (*i.$L)[idx+1:]", memberName); + writer.write("i.$L = &v", memberName); }); } }); diff --git a/service/route53/api_client.go b/service/route53/api_client.go index 48d72be7f3d..8a5a49d4417 100644 --- a/service/route53/api_client.go +++ b/service/route53/api_client.go @@ -207,183 +207,183 @@ func sanitizeHostedZoneIDInput(input interface{}) error { switch i := input.(type) { case *AssociateVPCWithHostedZoneInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *ChangeResourceRecordSetsInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *CreateHostedZoneInput: if i.DelegationSetId != nil { - values := strings.Split(*i.DelegationSetId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.DelegationSetId, `/`) + v := (*i.DelegationSetId)[idx+1:] i.DelegationSetId = &v } case *CreateQueryLoggingConfigInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *CreateReusableDelegationSetInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *CreateTrafficPolicyInstanceInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *CreateVPCAssociationAuthorizationInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *DeleteHostedZoneInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } case *DeleteReusableDelegationSetInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } case *DeleteVPCAssociationAuthorizationInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *DisassociateVPCFromHostedZoneInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *GetChangeInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } case *GetHostedZoneInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } case *GetHostedZoneLimitInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *GetReusableDelegationSetInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } case *GetReusableDelegationSetLimitInput: if i.DelegationSetId != nil { - values := strings.Split(*i.DelegationSetId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.DelegationSetId, `/`) + v := (*i.DelegationSetId)[idx+1:] i.DelegationSetId = &v } case *ListHostedZonesInput: if i.DelegationSetId != nil { - values := strings.Split(*i.DelegationSetId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.DelegationSetId, `/`) + v := (*i.DelegationSetId)[idx+1:] i.DelegationSetId = &v } case *ListHostedZonesByNameInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *ListQueryLoggingConfigsInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *ListResourceRecordSetsInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *ListTrafficPolicyInstancesInput: if i.HostedZoneIdMarker != nil { - values := strings.Split(*i.HostedZoneIdMarker, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneIdMarker, `/`) + v := (*i.HostedZoneIdMarker)[idx+1:] i.HostedZoneIdMarker = &v } case *ListTrafficPolicyInstancesByHostedZoneInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *ListTrafficPolicyInstancesByPolicyInput: if i.HostedZoneIdMarker != nil { - values := strings.Split(*i.HostedZoneIdMarker, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneIdMarker, `/`) + v := (*i.HostedZoneIdMarker)[idx+1:] i.HostedZoneIdMarker = &v } case *ListVPCAssociationAuthorizationsInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *TestDNSAnswerInput: if i.HostedZoneId != nil { - values := strings.Split(*i.HostedZoneId, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.HostedZoneId, `/`) + v := (*i.HostedZoneId)[idx+1:] i.HostedZoneId = &v } case *UpdateHostedZoneCommentInput: if i.Id != nil { - values := strings.Split(*i.Id, "/") - v := values[len(values)-1] + idx := strings.LastIndex(*i.Id, `/`) + v := (*i.Id)[idx+1:] i.Id = &v } From 8397dc18da900b8510ec0268848e6eca7e976f54 Mon Sep 17 00:00:00 2001 From: skotambkar Date: Wed, 21 Oct 2020 14:14:48 -0700 Subject: [PATCH 6/6] update go hash --- .../software/amazon/smithy/aws/go/codegen/AwsGoDependency.java | 2 +- service/route53/go.mod | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java index 96a90867410..8f898ee3bf4 100644 --- a/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java +++ b/codegen/smithy-aws-go-codegen/src/main/java/software/amazon/smithy/aws/go/codegen/AwsGoDependency.java @@ -82,6 +82,6 @@ protected static GoDependency module( } private static final class Versions { - private static final String AWS_SDK = "v0.27.1-0.20201021184031-883c13b4b7a8"; + private static final String AWS_SDK = "v0.27.1-0.20201021211102-ffda7ace423e"; } } diff --git a/service/route53/go.mod b/service/route53/go.mod index 73b6e3c26b0..a4e8abfae92 100644 --- a/service/route53/go.mod +++ b/service/route53/go.mod @@ -3,7 +3,7 @@ module github.com/aws/aws-sdk-go-v2/service/route53 go 1.15 require ( - github.com/aws/aws-sdk-go-v2 v0.27.1-0.20201021184031-883c13b4b7a8 + github.com/aws/aws-sdk-go-v2 v0.27.1-0.20201021211102-ffda7ace423e github.com/awslabs/smithy-go v0.2.0 )