From 62f7e92670f70fc98ddd7bd1ce0626ca06c0a804 Mon Sep 17 00:00:00 2001 From: AWS SDK for Go v2 automation user Date: Tue, 21 Jun 2022 18:14:39 +0000 Subject: [PATCH] Regenerated Clients --- .../0a5b63c51b814caea0ea019d1dbbc068.json | 8 + .../1723f254735f4d6c940acee532af5c9b.json | 8 + .../d372c4c4f6df4ebeab29899038449fcd.json | 8 + service/ec2/api_op_CreateCustomerGateway.go | 27 +- .../ec2/api_op_DescribeCustomerGateways.go | 28 +-- service/ec2/deserializers.go | 26 ++ service/ec2/serializers.go | 17 +- service/ec2/types/types.go | 17 +- service/ecs/api_op_CreateCluster.go | 2 +- service/ecs/api_op_CreateService.go | 14 +- service/ecs/api_op_CreateTaskSet.go | 6 +- service/ecs/api_op_DeleteTaskSet.go | 2 +- .../ecs/api_op_DeregisterContainerInstance.go | 8 +- service/ecs/api_op_DescribeServices.go | 237 ++++++++++++++++++ service/ecs/api_op_DescribeTasks.go | 3 +- service/ecs/api_op_DiscoverPollEndpoint.go | 10 +- service/ecs/api_op_ExecuteCommand.go | 6 +- service/ecs/api_op_UpdateService.go | 5 - service/ecs/doc.go | 23 +- service/ecs/types/types.go | 214 +++++++++------- .../wellarchitected/api_op_CreateLensShare.go | 8 +- .../api_op_CreateLensVersion.go | 8 +- .../wellarchitected/api_op_CreateWorkload.go | 10 +- service/wellarchitected/api_op_DeleteLens.go | 8 +- .../wellarchitected/api_op_DeleteLensShare.go | 8 +- service/wellarchitected/api_op_ExportLens.go | 8 +- service/wellarchitected/api_op_GetAnswer.go | 16 +- service/wellarchitected/api_op_GetLens.go | 8 +- .../wellarchitected/api_op_GetLensReview.go | 8 +- .../api_op_GetLensReviewReport.go | 8 +- .../api_op_GetLensVersionDifference.go | 16 +- service/wellarchitected/api_op_ImportLens.go | 8 +- service/wellarchitected/api_op_ListAnswers.go | 16 +- .../api_op_ListLensReviewImprovements.go | 16 +- .../wellarchitected/api_op_ListLensShares.go | 8 +- .../api_op_ListTagsForResource.go | 3 +- service/wellarchitected/api_op_TagResource.go | 3 +- .../wellarchitected/api_op_UntagResource.go | 3 +- .../wellarchitected/api_op_UpdateAnswer.go | 16 +- .../api_op_UpdateLensReview.go | 8 +- .../api_op_UpgradeLensReview.go | 8 +- service/wellarchitected/deserializers.go | 123 +++++++++ service/wellarchitected/types/enums.go | 18 ++ service/wellarchitected/types/types.go | 68 ++++- service/wellarchitected/validators.go | 3 - 45 files changed, 845 insertions(+), 231 deletions(-) create mode 100644 .changelog/0a5b63c51b814caea0ea019d1dbbc068.json create mode 100644 .changelog/1723f254735f4d6c940acee532af5c9b.json create mode 100644 .changelog/d372c4c4f6df4ebeab29899038449fcd.json diff --git a/.changelog/0a5b63c51b814caea0ea019d1dbbc068.json b/.changelog/0a5b63c51b814caea0ea019d1dbbc068.json new file mode 100644 index 00000000000..99abd06a903 --- /dev/null +++ b/.changelog/0a5b63c51b814caea0ea019d1dbbc068.json @@ -0,0 +1,8 @@ +{ + "id": "0a5b63c5-1b81-4cae-a0ea-019d1dbbc068", + "type": "feature", + "description": "Adds support for lens tagging, Adds support for multiple helpful-resource urls and multiple improvement-plan urls.", + "modules": [ + "service/wellarchitected" + ] +} \ No newline at end of file diff --git a/.changelog/1723f254735f4d6c940acee532af5c9b.json b/.changelog/1723f254735f4d6c940acee532af5c9b.json new file mode 100644 index 00000000000..3b435139c4a --- /dev/null +++ b/.changelog/1723f254735f4d6c940acee532af5c9b.json @@ -0,0 +1,8 @@ +{ + "id": "1723f254-735f-4d6c-940a-cee532af5c9b", + "type": "feature", + "description": "This release adds support for Private IP VPNs, a new feature allowing S2S VPN connections to use private ip addresses as the tunnel outside ip address over Direct Connect as transport.", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/d372c4c4f6df4ebeab29899038449fcd.json b/.changelog/d372c4c4f6df4ebeab29899038449fcd.json new file mode 100644 index 00000000000..1ddb654dc45 --- /dev/null +++ b/.changelog/d372c4c4f6df4ebeab29899038449fcd.json @@ -0,0 +1,8 @@ +{ + "id": "d372c4c4-f6df-4ebe-ab29-899038449fcd", + "type": "documentation", + "description": "Amazon ECS UpdateService now supports the following parameters: PlacementStrategies, PlacementConstraints and CapacityProviderStrategy.", + "modules": [ + "service/ecs" + ] +} \ No newline at end of file diff --git a/service/ec2/api_op_CreateCustomerGateway.go b/service/ec2/api_op_CreateCustomerGateway.go index 1530baab823..50754bbe1bb 100644 --- a/service/ec2/api_op_CreateCustomerGateway.go +++ b/service/ec2/api_op_CreateCustomerGateway.go @@ -11,16 +11,15 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Provides information to Amazon Web Services about your VPN customer gateway -// device. The customer gateway is the appliance at your end of the VPN connection. -// (The device on the Amazon Web Services side of the VPN connection is the virtual -// private gateway.) You must provide the internet-routable IP address of the -// customer gateway's external interface. The IP address must be static and can be -// behind a device performing network address translation (NAT). For devices that -// use Border Gateway Protocol (BGP), you can also provide the device's BGP -// Autonomous System Number (ASN). You can use an existing ASN assigned to your -// network. If you don't have an ASN already, you can use a private ASN. For more -// information, see Customer gateway options for your Site-to-Site VPN connection +// Provides information to Amazon Web Services about your customer gateway device. +// The customer gateway device is the appliance at your end of the VPN connection. +// You must provide the IP address of the customer gateway device’s external +// interface. The IP address must be static and can be behind a device performing +// network address translation (NAT). For devices that use Border Gateway Protocol +// (BGP), you can also provide the device's BGP Autonomous System Number (ASN). You +// can use an existing ASN assigned to your network. If you don't have an ASN +// already, you can use a private ASN. For more information, see Customer gateway +// options for your Site-to-Site VPN connection // (https://docs.aws.amazon.com/vpn/latest/s2svpn/cgw-options.html) in the Amazon // Web Services Site-to-Site VPN User Guide. To create more than one customer // gateway with the same VPN type, IP address, and BGP ASN, specify a unique device @@ -67,8 +66,12 @@ type CreateCustomerGatewayInput struct { // UnauthorizedOperation. DryRun *bool - // The Internet-routable IP address for the customer gateway's outside interface. - // The address must be static. + // IPv4 address for the customer gateway device's outside interface. The address + // must be static. + IpAddress *string + + // This member has been deprecated. The Internet-routable IP address for the + // customer gateway's outside interface. The address must be static. PublicIp *string // The tags to apply to the customer gateway. diff --git a/service/ec2/api_op_DescribeCustomerGateways.go b/service/ec2/api_op_DescribeCustomerGateways.go index 720a62782a2..458e7515301 100644 --- a/service/ec2/api_op_DescribeCustomerGateways.go +++ b/service/ec2/api_op_DescribeCustomerGateways.go @@ -55,24 +55,24 @@ type DescribeCustomerGatewaysInput struct { // * customer-gateway-id - The ID of the // customer gateway. // - // * ip-address - The IP address of the customer gateway's - // Internet-routable external interface. + // * ip-address - The IP address of the customer gateway + // device's external interface. // - // * state - The state of the customer - // gateway (pending | available | deleting | deleted). + // * state - The state of the customer gateway + // (pending | available | deleting | deleted). // - // * type - The type of - // customer gateway. Currently, the only supported type is ipsec.1. + // * type - The type of customer + // gateway. Currently, the only supported type is ipsec.1. // - // * tag: - The - // key/value combination of a tag assigned to the resource. Use the tag key in the - // filter name and the tag value as the filter value. For example, to find all - // resources that have a tag with the key Owner and the value TeamA, specify - // tag:Owner for the filter name and TeamA for the filter value. + // * tag: - The key/value + // combination of a tag assigned to the resource. Use the tag key in the filter + // name and the tag value as the filter value. For example, to find all resources + // that have a tag with the key Owner and the value TeamA, specify tag:Owner for + // the filter name and TeamA for the filter value. // - // * tag-key - The - // key of a tag assigned to the resource. Use this filter to find all resources - // assigned a tag with a specific key, regardless of the tag value. + // * tag-key - The key of a tag + // assigned to the resource. Use this filter to find all resources assigned a tag + // with a specific key, regardless of the tag value. Filters []types.Filter noSmithyDocumentSerde diff --git a/service/ec2/deserializers.go b/service/ec2/deserializers.go index b6432b13a0d..eb04a0a7a5b 100644 --- a/service/ec2/deserializers.go +++ b/service/ec2/deserializers.go @@ -118342,6 +118342,19 @@ func awsEc2query_deserializeDocumentVpnConnectionOptions(v **types.VpnConnection sv.LocalIpv6NetworkCidr = ptr.String(xtv) } + case strings.EqualFold("outsideIpAddressType", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.OutsideIpAddressType = ptr.String(xtv) + } + case strings.EqualFold("remoteIpv4NetworkCidr", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -118384,6 +118397,19 @@ func awsEc2query_deserializeDocumentVpnConnectionOptions(v **types.VpnConnection sv.StaticRoutesOnly = ptr.Bool(xtv) } + case strings.EqualFold("transportTransitGatewayAttachmentId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.TransportTransitGatewayAttachmentId = ptr.String(xtv) + } + case strings.EqualFold("tunnelInsideIpVersion", t.Name.Local): val, err := decoder.Value() if err != nil { diff --git a/service/ec2/serializers.go b/service/ec2/serializers.go index 11a559aaa92..f152f09a54a 100644 --- a/service/ec2/serializers.go +++ b/service/ec2/serializers.go @@ -42034,6 +42034,11 @@ func awsEc2query_serializeDocumentVpnConnectionOptionsSpecification(v *types.Vpn objectKey.String(*v.LocalIpv6NetworkCidr) } + if v.OutsideIpAddressType != nil { + objectKey := object.Key("OutsideIpAddressType") + objectKey.String(*v.OutsideIpAddressType) + } + if v.RemoteIpv4NetworkCidr != nil { objectKey := object.Key("RemoteIpv4NetworkCidr") objectKey.String(*v.RemoteIpv4NetworkCidr) @@ -42049,6 +42054,11 @@ func awsEc2query_serializeDocumentVpnConnectionOptionsSpecification(v *types.Vpn objectKey.Boolean(*v.StaticRoutesOnly) } + if v.TransportTransitGatewayAttachmentId != nil { + objectKey := object.Key("TransportTransitGatewayAttachmentId") + objectKey.String(*v.TransportTransitGatewayAttachmentId) + } + if len(v.TunnelInsideIpVersion) > 0 { objectKey := object.Key("TunnelInsideIpVersion") objectKey.String(string(v.TunnelInsideIpVersion)) @@ -43979,8 +43989,13 @@ func awsEc2query_serializeOpDocumentCreateCustomerGatewayInput(v *CreateCustomer objectKey.Boolean(*v.DryRun) } - if v.PublicIp != nil { + if v.IpAddress != nil { objectKey := object.Key("IpAddress") + objectKey.String(*v.IpAddress) + } + + if v.PublicIp != nil { + objectKey := object.Key("PublicIp") objectKey.String(*v.PublicIp) } diff --git a/service/ec2/types/types.go b/service/ec2/types/types.go index 4fa8dc7cacc..357715868ae 100644 --- a/service/ec2/types/types.go +++ b/service/ec2/types/types.go @@ -2056,7 +2056,7 @@ type CustomerGateway struct { // The name of customer gateway device. DeviceName *string - // The Internet-routable IP address of the customer gateway's outside interface. + // The IP address of the customer gateway device's outside interface. IpAddress *string // The current state of the customer gateway (pending | available | deleting | @@ -15745,6 +15745,10 @@ type VpnConnectionOptions struct { // The IPv6 CIDR on the customer gateway (on-premises) side of the VPN connection. LocalIpv6NetworkCidr *string + // The type of IPv4 address assigned to the outside interface of the customer + // gateway. Valid values: PrivateIpv4 | PublicIpv4 Default: PublicIpv4 + OutsideIpAddressType *string + // The IPv4 CIDR on the Amazon Web Services side of the VPN connection. RemoteIpv4NetworkCidr *string @@ -15755,6 +15759,9 @@ type VpnConnectionOptions struct { // be used for devices that don't support BGP. StaticRoutesOnly *bool + // The transit gateway attachment ID in use for the VPN tunnel. + TransportTransitGatewayAttachmentId *string + // Indicates whether the VPN tunnels process IPv4 or IPv6 traffic. TunnelInsideIpVersion TunnelInsideIpVersion @@ -15778,6 +15785,10 @@ type VpnConnectionOptionsSpecification struct { // Default: ::/0 LocalIpv6NetworkCidr *string + // The type of IPv4 address assigned to the outside interface of the customer + // gateway device. Valid values: PrivateIpv4 | PublicIpv4 Default: PublicIpv4 + OutsideIpAddressType *string + // The IPv4 CIDR on the Amazon Web Services side of the VPN connection. Default: // 0.0.0.0/0 RemoteIpv4NetworkCidr *string @@ -15791,6 +15802,10 @@ type VpnConnectionOptionsSpecification struct { // Use CreateVpnConnectionRoute to create a static route. Default: false StaticRoutesOnly *bool + // The transit gateway attachment ID to use for the VPN tunnel. Required if + // OutsideIpAddressType is set to PrivateIpv4. + TransportTransitGatewayAttachmentId *string + // Indicate whether the VPN tunnels process IPv4 or IPv6 traffic. Default: ipv4 TunnelInsideIpVersion TunnelInsideIpVersion diff --git a/service/ecs/api_op_CreateCluster.go b/service/ecs/api_op_CreateCluster.go index 3419e1a4d71..bed5b2b5bad 100644 --- a/service/ecs/api_op_CreateCluster.go +++ b/service/ecs/api_op_CreateCluster.go @@ -19,7 +19,7 @@ import ( // resources in other Amazon Web Services services on your behalf. However, if the // IAM user that makes the call doesn't have permissions to create the // service-linked role, it isn't created. For more information, see Using -// Service-Linked Roles for Amazon ECS +// service-linked roles for Amazon ECS // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using-service-linked-roles.html) // in the Amazon Elastic Container Service Developer Guide. func (c *Client) CreateCluster(ctx context.Context, params *CreateClusterInput, optFns ...func(*Options)) (*CreateClusterOutput, error) { diff --git a/service/ecs/api_op_CreateService.go b/service/ecs/api_op_CreateService.go index 26e61eaf5cf..d7f84e5cbe4 100644 --- a/service/ecs/api_op_CreateService.go +++ b/service/ecs/api_op_CreateService.go @@ -18,7 +18,7 @@ import ( // maintaining the desired count of tasks in your service, you can optionally run // your service behind one or more load balancers. The load balancers distribute // traffic across the tasks that are associated with the service. For more -// information, see Service Load Balancing +// information, see Service load balancing // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-load-balancing.html) // in the Amazon Elastic Container Service Developer Guide. Tasks for services that // don't use a load balancer are considered healthy if they're in the RUNNING @@ -30,8 +30,8 @@ import ( // scheduling strategy places and maintains your desired number of tasks across // your cluster. By default, the service scheduler spreads tasks across // Availability Zones. You can use task placement strategies and constraints to -// customize task placement decisions. For more information, see Service Scheduler -// Concepts +// customize task placement decisions. For more information, see Service scheduler +// concepts // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs_services.html) // in the Amazon Elastic Container Service Developer Guide. // @@ -42,7 +42,7 @@ import ( // running tasks. It also stops tasks that don't meet the placement constraints. // When using this strategy, you don't need to specify a desired number of tasks, a // task placement strategy, or use Service Auto Scaling policies. For more -// information, see Service Scheduler Concepts +// information, see Service scheduler concepts // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs_services.html) // in the Amazon Elastic Container Service Developer Guide. // @@ -87,7 +87,7 @@ import ( // uses the EXTERNAL deployment controller, you can specify only parameters that // aren't controlled at the task set level. The only required parameter is the // service name. You control your services using the CreateTaskSet operation. For -// more information, see Amazon ECS Deployment Types +// more information, see Amazon ECS deployment types // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html) // in the Amazon Elastic Container Service Developer Guide. When the service // scheduler launches new tasks, it determines task placement in your cluster using @@ -167,7 +167,7 @@ type CreateServiceInput struct { DesiredCount *int32 // Specifies whether to turn on Amazon ECS managed tags for the tasks within the - // service. For more information, see Tagging Your Amazon ECS Resources + // service. For more information, see Tagging your Amazon ECS resources // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-using-tags.html) // in the Amazon Elastic Container Service Developer Guide. EnableECSManagedTags bool @@ -210,7 +210,7 @@ type CreateServiceInput struct { LaunchType types.LaunchType // A load balancer object representing the load balancers to use with your service. - // For more information, see Service Load Balancing + // For more information, see Service load balancing // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-load-balancing.html) // in the Amazon Elastic Container Service Developer Guide. If the service uses the // rolling update (ECS) deployment controller and using either an Application Load diff --git a/service/ecs/api_op_CreateTaskSet.go b/service/ecs/api_op_CreateTaskSet.go index 3f8e9613392..ed4b6b7eba0 100644 --- a/service/ecs/api_op_CreateTaskSet.go +++ b/service/ecs/api_op_CreateTaskSet.go @@ -13,7 +13,7 @@ import ( // Create a task set in the specified cluster and service. This is used when a // service uses the EXTERNAL deployment controller type. For more information, see -// Amazon ECS Deployment Types +// Amazon ECS deployment types // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html) // in the Amazon Elastic Container Service Developer Guide. func (c *Client) CreateTaskSet(ctx context.Context, params *CreateTaskSetInput, optFns ...func(*Options)) (*CreateTaskSetOutput, error) { @@ -81,7 +81,7 @@ type CreateTaskSetInput struct { ExternalId *string // The launch type that new tasks in the task set uses. For more information, see - // Amazon ECS Launch Types + // Amazon ECS launch types // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_types.html) // in the Amazon Elastic Container Service Developer Guide. If a launchType is // specified, the capacityProviderStrategy parameter must be omitted. @@ -105,7 +105,7 @@ type CreateTaskSetInput struct { Scale *types.Scale // The details of the service discovery registries to assign to this task set. For - // more information, see Service Discovery + // more information, see Service discovery // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-discovery.html). ServiceRegistries []types.ServiceRegistry diff --git a/service/ecs/api_op_DeleteTaskSet.go b/service/ecs/api_op_DeleteTaskSet.go index c21c881af2e..0fabbd8b851 100644 --- a/service/ecs/api_op_DeleteTaskSet.go +++ b/service/ecs/api_op_DeleteTaskSet.go @@ -13,7 +13,7 @@ import ( // Deletes a specified task set within a service. This is used when a service uses // the EXTERNAL deployment controller type. For more information, see Amazon ECS -// Deployment Types +// deployment types // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html) // in the Amazon Elastic Container Service Developer Guide. func (c *Client) DeleteTaskSet(ctx context.Context, params *DeleteTaskSetInput, optFns ...func(*Options)) (*DeleteTaskSetOutput, error) { diff --git a/service/ecs/api_op_DeregisterContainerInstance.go b/service/ecs/api_op_DeregisterContainerInstance.go index 59be1ce979d..1bce46de057 100644 --- a/service/ecs/api_op_DeregisterContainerInstance.go +++ b/service/ecs/api_op_DeregisterContainerInstance.go @@ -40,11 +40,9 @@ func (c *Client) DeregisterContainerInstance(ctx context.Context, params *Deregi type DeregisterContainerInstanceInput struct { // The container instance ID or full ARN of the container instance to deregister. - // The ARN contains the arn:aws:ecs namespace, followed by the Region of the - // container instance, the Amazon Web Services account ID of the container instance - // owner, the container-instance namespace, and then the container instance ID. For - // example, - // arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID. + // For more information about the ARN format, see Amazon Resource Name (ARN) + // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids) + // in the Amazon ECS Developer Guide. // // This member is required. ContainerInstance *string diff --git a/service/ecs/api_op_DescribeServices.go b/service/ecs/api_op_DescribeServices.go index a2ffbced8fe..057fcbc528c 100644 --- a/service/ecs/api_op_DescribeServices.go +++ b/service/ecs/api_op_DescribeServices.go @@ -13,6 +13,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" smithywaiter "github.com/aws/smithy-go/waiter" "github.com/jmespath/go-jmespath" + "strconv" "time" ) @@ -330,6 +331,242 @@ func servicesInactiveStateRetryable(ctx context.Context, input *DescribeServices return true, nil } +// ServicesStableWaiterOptions are waiter options for ServicesStableWaiter +type ServicesStableWaiterOptions struct { + + // Set of options to modify how an operation is invoked. These apply to all + // operations invoked for this client. Use functional options on operation call to + // modify this list for per operation behavior. + APIOptions []func(*middleware.Stack) error + + // MinDelay is the minimum amount of time to delay between retries. If unset, + // ServicesStableWaiter will use default minimum delay of 15 seconds. Note that + // MinDelay must resolve to a value lesser than or equal to the MaxDelay. + MinDelay time.Duration + + // MaxDelay is the maximum amount of time to delay between retries. If unset or set + // to zero, ServicesStableWaiter will use default max delay of 120 seconds. Note + // that MaxDelay must resolve to value greater than or equal to the MinDelay. + MaxDelay time.Duration + + // LogWaitAttempts is used to enable logging for waiter retry attempts + LogWaitAttempts bool + + // Retryable is function that can be used to override the service defined + // waiter-behavior based on operation output, or returned error. This function is + // used by the waiter to decide if a state is retryable or a terminal state. By + // default service-modeled logic will populate this option. This option can thus be + // used to define a custom waiter state with fall-back to service-modeled waiter + // state mutators.The function returns an error in case of a failure state. In case + // of retry state, this function returns a bool value of true and nil error, while + // in case of success it returns a bool value of false and nil error. + Retryable func(context.Context, *DescribeServicesInput, *DescribeServicesOutput, error) (bool, error) +} + +// ServicesStableWaiter defines the waiters for ServicesStable +type ServicesStableWaiter struct { + client DescribeServicesAPIClient + + options ServicesStableWaiterOptions +} + +// NewServicesStableWaiter constructs a ServicesStableWaiter. +func NewServicesStableWaiter(client DescribeServicesAPIClient, optFns ...func(*ServicesStableWaiterOptions)) *ServicesStableWaiter { + options := ServicesStableWaiterOptions{} + options.MinDelay = 15 * time.Second + options.MaxDelay = 120 * time.Second + options.Retryable = servicesStableStateRetryable + + for _, fn := range optFns { + fn(&options) + } + return &ServicesStableWaiter{ + client: client, + options: options, + } +} + +// Wait calls the waiter function for ServicesStable waiter. The maxWaitDur is the +// maximum wait duration the waiter will wait. The maxWaitDur is required and must +// be greater than zero. +func (w *ServicesStableWaiter) Wait(ctx context.Context, params *DescribeServicesInput, maxWaitDur time.Duration, optFns ...func(*ServicesStableWaiterOptions)) error { + _, err := w.WaitForOutput(ctx, params, maxWaitDur, optFns...) + return err +} + +// WaitForOutput calls the waiter function for ServicesStable waiter and returns +// the output of the successful operation. The maxWaitDur is the maximum wait +// duration the waiter will wait. The maxWaitDur is required and must be greater +// than zero. +func (w *ServicesStableWaiter) WaitForOutput(ctx context.Context, params *DescribeServicesInput, maxWaitDur time.Duration, optFns ...func(*ServicesStableWaiterOptions)) (*DescribeServicesOutput, error) { + if maxWaitDur <= 0 { + return nil, fmt.Errorf("maximum wait time for waiter must be greater than zero") + } + + options := w.options + for _, fn := range optFns { + fn(&options) + } + + if options.MaxDelay <= 0 { + options.MaxDelay = 120 * time.Second + } + + if options.MinDelay > options.MaxDelay { + return nil, fmt.Errorf("minimum waiter delay %v must be lesser than or equal to maximum waiter delay of %v.", options.MinDelay, options.MaxDelay) + } + + ctx, cancelFn := context.WithTimeout(ctx, maxWaitDur) + defer cancelFn() + + logger := smithywaiter.Logger{} + remainingTime := maxWaitDur + + var attempt int64 + for { + + attempt++ + apiOptions := options.APIOptions + start := time.Now() + + if options.LogWaitAttempts { + logger.Attempt = attempt + apiOptions = append([]func(*middleware.Stack) error{}, options.APIOptions...) + apiOptions = append(apiOptions, logger.AddLogger) + } + + out, err := w.client.DescribeServices(ctx, params, func(o *Options) { + o.APIOptions = append(o.APIOptions, apiOptions...) + }) + + retryable, err := options.Retryable(ctx, params, out, err) + if err != nil { + return nil, err + } + if !retryable { + return out, nil + } + + remainingTime -= time.Since(start) + if remainingTime < options.MinDelay || remainingTime <= 0 { + break + } + + // compute exponential backoff between waiter retries + delay, err := smithywaiter.ComputeDelay( + attempt, options.MinDelay, options.MaxDelay, remainingTime, + ) + if err != nil { + return nil, fmt.Errorf("error computing waiter delay, %w", err) + } + + remainingTime -= delay + // sleep for the delay amount before invoking a request + if err := smithytime.SleepWithContext(ctx, delay); err != nil { + return nil, fmt.Errorf("request cancelled while waiting, %w", err) + } + } + return nil, fmt.Errorf("exceeded max wait time for ServicesStable waiter") +} + +func servicesStableStateRetryable(ctx context.Context, input *DescribeServicesInput, output *DescribeServicesOutput, err error) (bool, error) { + + if err == nil { + pathValue, err := jmespath.Search("failures[].reason", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "MISSING" + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) == expectedValue { + return false, fmt.Errorf("waiter state transitioned to Failure") + } + } + } + + if err == nil { + pathValue, err := jmespath.Search("services[].status", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "DRAINING" + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) == expectedValue { + return false, fmt.Errorf("waiter state transitioned to Failure") + } + } + } + + if err == nil { + pathValue, err := jmespath.Search("services[].status", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "INACTIVE" + listOfValues, ok := pathValue.([]interface{}) + if !ok { + return false, fmt.Errorf("waiter comparator expected list got %T", pathValue) + } + + for _, v := range listOfValues { + value, ok := v.(*string) + if !ok { + return false, fmt.Errorf("waiter comparator expected *string value, got %T", pathValue) + } + + if string(*value) == expectedValue { + return false, fmt.Errorf("waiter state transitioned to Failure") + } + } + } + + if err == nil { + pathValue, err := jmespath.Search("length(services[?!(length(deployments) == `1` && runningCount == desiredCount)]) == `0`", output) + if err != nil { + return false, fmt.Errorf("error evaluating waiter state: %w", err) + } + + expectedValue := "true" + bv, err := strconv.ParseBool(expectedValue) + if err != nil { + return false, fmt.Errorf("error parsing boolean from string %w", err) + } + value, ok := pathValue.(bool) + if !ok { + return false, fmt.Errorf("waiter comparator expected bool value got %T", pathValue) + } + + if value == bv { + return false, nil + } + } + + return true, nil +} + func newServiceMetadataMiddleware_opDescribeServices(region string) *awsmiddleware.RegisterServiceMetadata { return &awsmiddleware.RegisterServiceMetadata{ Region: region, diff --git a/service/ecs/api_op_DescribeTasks.go b/service/ecs/api_op_DescribeTasks.go index 4610d63e00a..eba05ff4b2c 100644 --- a/service/ecs/api_op_DescribeTasks.go +++ b/service/ecs/api_op_DescribeTasks.go @@ -16,7 +16,8 @@ import ( "time" ) -// Describes a specified task or tasks. +// Describes a specified task or tasks. Currently, stopped tasks appear in the +// returned results for at least one hour. func (c *Client) DescribeTasks(ctx context.Context, params *DescribeTasksInput, optFns ...func(*Options)) (*DescribeTasksOutput, error) { if params == nil { params = &DescribeTasksInput{} diff --git a/service/ecs/api_op_DiscoverPollEndpoint.go b/service/ecs/api_op_DiscoverPollEndpoint.go index fc074c58989..9a82f2d2294 100644 --- a/service/ecs/api_op_DiscoverPollEndpoint.go +++ b/service/ecs/api_op_DiscoverPollEndpoint.go @@ -34,12 +34,10 @@ type DiscoverPollEndpointInput struct { // container instance belongs to. Cluster *string - // The container instance ID or full ARN of the container instance. The ARN - // contains the arn:aws:ecs namespace, followed by the Region of the container - // instance, the Amazon Web Services account ID of the container instance owner, - // the container-instance namespace, and then the container instance ID. For - // example, - // arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID. + // The container instance ID or full ARN of the container instance. For more + // information about the ARN format, see Amazon Resource Name (ARN) + // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids) + // in the Amazon ECS Developer Guide. ContainerInstance *string noSmithyDocumentSerde diff --git a/service/ecs/api_op_ExecuteCommand.go b/service/ecs/api_op_ExecuteCommand.go index b05f57493c8..fc89cff325b 100644 --- a/service/ecs/api_op_ExecuteCommand.go +++ b/service/ecs/api_op_ExecuteCommand.go @@ -11,7 +11,11 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Runs a command remotely on a container within a task. +// Runs a command remotely on a container within a task. If you use a condition key +// in your IAM policy to refine the conditions for the policy statement, for +// example limit the actions to a specific cluster, you recevie an +// AccessDeniedException when there is a mismatch between the condition key value +// and the corresponding parameter value. func (c *Client) ExecuteCommand(ctx context.Context, params *ExecuteCommandInput, optFns ...func(*Options)) (*ExecuteCommandOutput, error) { if params == nil { params = &ExecuteCommandInput{} diff --git a/service/ecs/api_op_UpdateService.go b/service/ecs/api_op_UpdateService.go index 6d43f8adb46..1f5bd4c193b 100644 --- a/service/ecs/api_op_UpdateService.go +++ b/service/ecs/api_op_UpdateService.go @@ -11,11 +11,6 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Updating the task placement strategies and constraints on an Amazon ECS service -// remains in preview and is a Beta Service as defined by and subject to the Beta -// Service Participation Service Terms located at -// https://aws.amazon.com/service-terms (https://aws.amazon.com/service-terms) -// ("Beta Terms"). These Beta Terms apply to your participation in this preview. // Modifies the parameters of a service. For services using the rolling update // (ECS) you can update the desired count, deployment configuration, network // configuration, load balancers, service registries, enable ECS managed tags diff --git a/service/ecs/doc.go b/service/ecs/doc.go index e5039bb91b1..0f15f7eccd8 100644 --- a/service/ecs/doc.go +++ b/service/ecs/doc.go @@ -5,16 +5,17 @@ // // Amazon Elastic Container Service Amazon Elastic Container Service (Amazon ECS) // is a highly scalable, fast, container management service. It makes it easy to -// run, stop, and manage Docker containers on a cluster. You can host your cluster -// on a serverless infrastructure that's managed by Amazon ECS by launching your +// run, stop, and manage Docker containers. You can host your cluster on a +// serverless infrastructure that's managed by Amazon ECS by launching your // services or tasks on Fargate. For more control, you can host your tasks on a -// cluster of Amazon Elastic Compute Cloud (Amazon EC2) instances that you manage. -// Amazon ECS makes it easy to launch and stop container-based applications with -// simple API calls. This makes it easy to get the state of your cluster from a -// centralized service, and gives you access to many familiar Amazon EC2 features. -// You can use Amazon ECS to schedule the placement of containers across your -// cluster based on your resource needs, isolation policies, and availability -// requirements. With Amazon ECS, you don't need to operate your own cluster -// management and configuration management systems. You also don't need to worry -// about scaling your management infrastructure. +// cluster of Amazon Elastic Compute Cloud (Amazon EC2) or External (on-premises) +// instances that you manage. Amazon ECS makes it easy to launch and stop +// container-based applications with simple API calls. This makes it easy to get +// the state of your cluster from a centralized service, and gives you access to +// many familiar Amazon EC2 features. You can use Amazon ECS to schedule the +// placement of containers across your cluster based on your resource needs, +// isolation policies, and availability requirements. With Amazon ECS, you don't +// need to operate your own cluster management and configuration management +// systems. You also don't need to worry about scaling your management +// infrastructure. package ecs diff --git a/service/ecs/types/types.go b/service/ecs/types/types.go index 874d0fbfa72..2ce0e8ffd8a 100644 --- a/service/ecs/types/types.go +++ b/service/ecs/types/types.go @@ -270,24 +270,23 @@ type Cluster struct { ActiveServicesCount int32 // The resources attached to a cluster. When using a capacity provider with a - // cluster, the Auto Scaling plan that's created is returned as a cluster - // attachment. + // cluster, the capacity provider and associated resources are returned as cluster + // attachments. Attachments []Attachment // The status of the capacity providers associated with the cluster. The following // are the states that are returned. UPDATE_IN_PROGRESS The available capacity - // providers for the cluster are updating. This occurs when the Auto Scaling plan - // is provisioning or deprovisioning. UPDATE_COMPLETE The capacity providers have - // successfully updated. UPDATE_FAILED The capacity provider updates failed. + // providers for the cluster are updating. UPDATE_COMPLETE The capacity providers + // have successfully updated. UPDATE_FAILED The capacity provider updates failed. AttachmentsStatus *string // The capacity providers associated with the cluster. CapacityProviders []string - // The Amazon Resource Name (ARN) that identifies the cluster. The ARN contains the - // arn:aws:ecs namespace, followed by the Region of the cluster, the Amazon Web - // Services account ID of the cluster owner, the cluster namespace, and then the - // cluster name. For example, arn:aws:ecs:region:012345678910:cluster/test. + // The Amazon Resource Name (ARN) that identifies the cluster. For more information + // about the ARN format, see Amazon Resource Name (ARN) + // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids) + // in the Amazon ECS Developer Guide. ClusterArn *string // A user-generated string that you use to identify your cluster. @@ -820,10 +819,10 @@ type ContainerDefinition struct { // memoryReservation, then that value is subtracted from the available memory // resources for the container instance where the container is placed. Otherwise, // the value of memory is used. The Docker 20.10.0 or later daemon reserves a - // minimum of 6 MiB of memory for a container, so you should not specify fewer than - // 6 MiB of memory for your containers. The Docker 19.03.13-ce or earlier daemon - // reserves a minimum of 4 MiB of memory for a container, so you should not specify - // fewer than 4 MiB of memory for your containers. + // minimum of 6 MiB of memory for a container. So, don't specify less than 6 MiB of + // memory for your containers. The Docker 19.03.13-ce or earlier daemon reserves a + // minimum of 4 MiB of memory for a container. So, don't specify less than 4 MiB of + // memory for your containers. Memory *int32 // The soft limit (in MiB) of memory to reserve for the container. When system @@ -1134,21 +1133,21 @@ type ContainerDependency struct { noSmithyDocumentSerde } -// An EC2 instance that's running the Amazon ECS agent and has been registered with -// a cluster. +// An Amazon EC2 or External instance that's running the Amazon ECS agent and has +// been registered with a cluster. type ContainerInstance struct { - // This parameter returns true if the agent is connected to Amazon ECS. Registered - // instances with an agent that may be unhealthy or stopped return false. Only - // instances connected to an agent can accept placement requests. + // This parameter returns true if the agent is connected to Amazon ECS. An instance + // with an agent that may be unhealthy or stopped return false. Only instances + // connected to an agent can accept task placement requests. AgentConnected bool // The status of the most recent agent update. If an update wasn't ever requested, // this value is NULL. AgentUpdateStatus AgentUpdateStatus - // The resources attached to a container instance, such as elastic network - // interfaces. + // The resources attached to a container instance, such as an elastic network + // interface. Attachments []Attachment // The attributes set for the container instance, either by the Amazon ECS @@ -1159,11 +1158,10 @@ type ContainerInstance struct { // The capacity provider that's associated with the container instance. CapacityProviderName *string - // The Amazon Resource Name (ARN) of the container instance. The ARN contains the - // arn:aws:ecs namespace, followed by the Region of the container instance, the - // Amazon Web Services account ID of the container instance owner, the - // container-instance namespace, and then the container instance ID. For example, - // arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID. + // The Amazon Resource Name (ARN) of the container instance. For more information + // about the ARN format, see Amazon Resource Name (ARN) + // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids) + // in the Amazon ECS Developer Guide. ContainerInstanceArn *string // The ID of the container instance. For Amazon EC2 instances, this value is the @@ -1214,7 +1212,7 @@ type ContainerInstance struct { // The ACTIVE status indicates that the container instance can accept tasks. The // DRAINING indicates that new tasks aren't placed on the container instance and // any service tasks running on the container instance are removed if possible. For - // more information, see Container Instance Draining + // more information, see Container instance draining // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/container-instance-draining.html) // in the Amazon Elastic Container Service Developer Guide. Status *string @@ -1477,52 +1475,80 @@ type DeploymentConfiguration struct { // completed successfully. DeploymentCircuitBreaker *DeploymentCircuitBreaker - // If a service is using the rolling update (ECS) deployment type, the maximum - // percent parameter represents an upper limit on the number of tasks in a service - // that are allowed in the RUNNING or PENDING state during a deployment, as a - // percentage of the desired number of tasks (rounded down to the nearest integer), - // and while any container instances are in the DRAINING state if the service - // contains tasks using the EC2 launch type. This parameter enables you to define - // the deployment batch size. For example, if your service has a desired number of - // four tasks and a maximum percent value of 200%, the scheduler may start four new - // tasks before stopping the four older tasks (provided that the cluster resources - // required to do this are available). The default value for maximum percent is - // 200%. If a service is using the blue/green (CODE_DEPLOY) or EXTERNAL deployment - // types and tasks that use the EC2 launch type, the maximum percent value is set - // to the default value and is used to define the upper limit on the number of the - // tasks in the service that remain in the RUNNING state while the container - // instances are in the DRAINING state. If the tasks in the service use the Fargate - // launch type, the maximum percent value is not used, although it is returned when - // describing your service. + // If a service is using the rolling update (ECS) deployment type, the + // maximumPercent parameter represents an upper limit on the number of your + // service's tasks that are allowed in the RUNNING or PENDING state during a + // deployment, as a percentage of the desiredCount (rounded down to the nearest + // integer). This parameter enables you to define the deployment batch size. For + // example, if your service is using the REPLICA service scheduler and has a + // desiredCount of four tasks and a maximumPercent value of 200%, the scheduler may + // start four new tasks before stopping the four older tasks (provided that the + // cluster resources required to do this are available). The default maximumPercent + // value for a service using the REPLICA service scheduler is 200%. If a service is + // using either the blue/green (CODE_DEPLOY) or EXTERNAL deployment types and tasks + // that use the EC2 launch type, the maximum percent value is set to the default + // value and is used to define the upper limit on the number of the tasks in the + // service that remain in the RUNNING state while the container instances are in + // the DRAINING state. If the tasks in the service use the Fargate launch type, the + // maximum percent value is not used, although it is returned when describing your + // service. MaximumPercent *int32 - // If a service is using the rolling update (ECS) deployment type, the minimum - // healthy percent represents a lower limit on the number of tasks in a service - // that must remain in the RUNNING state during a deployment, as a percentage of - // the desired number of tasks (rounded up to the nearest integer), and while any - // container instances are in the DRAINING state if the service contains tasks - // using the EC2 launch type. This parameter enables you to deploy without using - // additional cluster capacity. For example, if your service has a desired number - // of four tasks and a minimum healthy percent of 50%, the scheduler may stop two - // existing tasks to free up cluster capacity before starting two new tasks. Tasks - // for services that do not use a load balancer are considered healthy if they're - // in the RUNNING state; tasks for services that do use a load balancer are - // considered healthy if they're in the RUNNING state and they're reported as - // healthy by the load balancer. The default value for minimum healthy percent is - // 100%. If a service is using the blue/green (CODE_DEPLOY) or EXTERNAL deployment - // types and tasks that use the EC2 launch type, the minimum healthy percent value - // is set to the default value and is used to define the lower limit on the number - // of the tasks in the service that remain in the RUNNING state while the container - // instances are in the DRAINING state. If the tasks in the service use the Fargate - // launch type, the minimum healthy percent value is not used, although it is - // returned when describing your service. + // If a service is using the rolling update (ECS) deployment type, the + // minimumHealthyPercent represents a lower limit on the number of your service's + // tasks that must remain in the RUNNING state during a deployment, as a percentage + // of the desiredCount (rounded up to the nearest integer). This parameter enables + // you to deploy without using additional cluster capacity. For example, if your + // service has a desiredCount of four tasks and a minimumHealthyPercent of 50%, the + // service scheduler may stop two existing tasks to free up cluster capacity before + // starting two new tasks. For services that do not use a load balancer, the + // following should be noted: + // + // * A service is considered healthy if all essential + // containers within the tasks in the service pass their health checks. + // + // * If a + // task has no essential containers with a health check defined, the service + // scheduler will wait for 40 seconds after a task reaches a RUNNING state before + // the task is counted towards the minimum healthy percent total. + // + // * If a task has + // one or more essential containers with a health check defined, the service + // scheduler will wait for the task to reach a healthy status before counting it + // towards the minimum healthy percent total. A task is considered healthy when all + // essential containers within the task have passed their health checks. The amount + // of time the service scheduler can wait for is determined by the container health + // check settings. + // + // For services are that do use a load balancer, the following + // should be noted: + // + // * If a task has no essential containers with a health check + // defined, the service scheduler will wait for the load balancer target group + // health check to return a healthy status before counting the task towards the + // minimum healthy percent total. + // + // * If a task has an essential container with a + // health check defined, the service scheduler will wait for both the task to reach + // a healthy status and the load balancer target group health check to return a + // healthy status before counting the task towards the minimum healthy percent + // total. + // + // If a service is using either the blue/green (CODE_DEPLOY) or EXTERNAL + // deployment types and is running tasks that use the EC2 launch type, the minimum + // healthy percent value is set to the default value and is used to define the + // lower limit on the number of the tasks in the service that remain in the RUNNING + // state while the container instances are in the DRAINING state. If a service is + // using either the blue/green (CODE_DEPLOY) or EXTERNAL deployment types and is + // running tasks that use the Fargate launch type, the minimum healthy percent + // value is not used, although it is returned when describing your service. MinimumHealthyPercent *int32 noSmithyDocumentSerde } // The deployment controller to use for the service. For more information, see -// Amazon ECS Deployment Types +// Amazon ECS deployment types // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html) // in the Amazon Elastic Container Service Developer Guide. type DeploymentController struct { @@ -1619,8 +1645,8 @@ type EFSAuthorizationConfig struct { // directory value specified in the EFSVolumeConfiguration must either be omitted // or set to / which will enforce the path set on the EFS access point. If an // access point is used, transit encryption must be enabled in the - // EFSVolumeConfiguration. For more information, see Working with Amazon EFS Access - // Points (https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html) in the + // EFSVolumeConfiguration. For more information, see Working with Amazon EFS access + // points (https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html) in the // Amazon Elastic File System User Guide. AccessPointId *string @@ -1628,7 +1654,7 @@ type EFSAuthorizationConfig struct { // definition when mounting the Amazon EFS file system. If enabled, transit // encryption must be enabled in the EFSVolumeConfiguration. If this parameter is // omitted, the default value of DISABLED is used. For more information, see Using - // Amazon EFS Access Points + // Amazon EFS access points // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/efs-volumes.html#efs-volume-accesspoints) // in the Amazon Elastic Container Service Developer Guide. Iam EFSAuthorizationConfigIAM @@ -1637,7 +1663,7 @@ type EFSAuthorizationConfig struct { } // This parameter is specified when you're using an Amazon Elastic File System file -// system for task storage. For more information, see Amazon EFS Volumes +// system for task storage. For more information, see Amazon EFS volumes // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/efs-volumes.html) // in the Amazon Elastic Container Service Developer Guide. type EFSVolumeConfiguration struct { @@ -1661,7 +1687,7 @@ type EFSVolumeConfiguration struct { // Determines whether to use encryption for Amazon EFS data in transit between the // Amazon ECS host and the Amazon EFS server. Transit encryption must be enabled if // Amazon EFS IAM authorization is used. If this parameter is omitted, the default - // value of DISABLED is used. For more information, see Encrypting Data in Transit + // value of DISABLED is used. For more information, see Encrypting data in transit // (https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html) in the // Amazon Elastic File System User Guide. TransitEncryption EFSTransitEncryption @@ -1669,7 +1695,7 @@ type EFSVolumeConfiguration struct { // The port to use when sending encrypted data between the Amazon ECS host and the // Amazon EFS server. If you do not specify a transit encryption port, it will use // the port selection strategy that the Amazon EFS mount helper uses. For more - // information, see EFS Mount Helper + // information, see EFS mount helper // (https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html) in the Amazon // Elastic File System User Guide. TransitEncryptionPort *int32 @@ -1807,8 +1833,8 @@ type Failure struct { } // The FireLens configuration for the container. This is used to specify and -// configure a log router for container logs. For more information, see Custom Log -// Routing +// configure a log router for container logs. For more information, see Custom log +// routing // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using_firelens.html) // in the Amazon Elastic Container Service Developer Guide. type FirelensConfiguration struct { @@ -1823,8 +1849,8 @@ type FirelensConfiguration struct { // metadata, such as the task, task definition, cluster, and container instance // details to the log event. If specified, the syntax to use is // "options":{"enable-ecs-log-metadata":"true|false","config-file-type:"s3|file","config-file-value":"arn:aws:s3:::mybucket/fluent.conf|filepath"}. - // For more information, see Creating a Task Definition that Uses a FireLens - // Configuration + // For more information, see Creating a task definition that uses a FireLens + // configuration // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using_firelens.html#firelens-taskdef) // in the Amazon Elastic Container Service Developer Guide. Tasks hosted on Fargate // only support the file configuration file type. @@ -1836,15 +1862,15 @@ type FirelensConfiguration struct { // The authorization configuration details for Amazon FSx for Windows File Server // file system. See FSxWindowsFileServerVolumeConfiguration // (https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_FSxWindowsFileServerVolumeConfiguration.html) -// in the Amazon Elastic Container Service API Reference. For more information and -// the input format, see Amazon FSx for Windows File Server Volumes +// in the Amazon ECS API Reference. For more information and the input format, see +// Amazon FSx for Windows File Server Volumes // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/wfsx-volumes.html) // in the Amazon Elastic Container Service Developer Guide. type FSxWindowsFileServerAuthorizationConfig struct { // The authorization credential option to use. The authorization credential options // can be provided using either the Amazon Resource Name (ARN) of an Secrets - // Manager secret or SSM Parameter Store parameter. The ARNs refer to the stored + // Manager secret or SSM Parameter Store parameter. The ARN refers to the stored // credentials. // // This member is required. @@ -1863,7 +1889,7 @@ type FSxWindowsFileServerAuthorizationConfig struct { // This parameter is specified when you're using Amazon FSx for Windows File Server // (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/what-is.html) file system // for task storage. For more information and the input format, see Amazon FSx for -// Windows File Server Volumes +// Windows File Server volumes // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/wfsx-volumes.html) // in the Amazon Elastic Container Service Developer Guide. type FSxWindowsFileServerVolumeConfiguration struct { @@ -1932,12 +1958,12 @@ type FSxWindowsFileServerVolumeConfiguration struct { // // * Container // health checks require version 1.17.0 or greater of the Amazon ECS container -// agent. For more information, see Updating the Amazon ECS Container Agent +// agent. For more information, see Updating the Amazon ECS container agent // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-agent-update.html). // // * // Container health checks are supported for Fargate tasks if you're using platform -// version 1.1.0 or greater. For more information, see Fargate Platform Versions +// version 1.1.0 or greater. For more information, see Fargate platform versions // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html). // // * @@ -2214,7 +2240,7 @@ type LinuxParameters struct { // tasks to register to and deregister from load balancers. We recommend that you // verify this on a test environment before you update the Elastic Load Balancing // configuration. A service-linked role is required for services that use multiple -// target groups. For more information, see Service-linked roles +// target groups. For more information, see Using service-linked roles // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using-service-linked-roles.html) // in the Amazon Elastic Container Service Developer Guide. type LoadBalancer struct { @@ -2241,12 +2267,12 @@ type LoadBalancer struct { // specified when using an Application Load Balancer or Network Load Balancer. If // you're using a Classic Load Balancer, omit the target group ARN. For services // using the ECS deployment controller, you can specify one or multiple target - // groups. For more information, see Registering Multiple Target Groups with a - // Service + // groups. For more information, see Registering multiple target groups with a + // service // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/register-multiple-targetgroups.html) // in the Amazon Elastic Container Service Developer Guide. For services using the // CODE_DEPLOY deployment controller, you're required to define two target groups - // for the load balancer. For more information, see Blue/Green Deployment with + // for the load balancer. For more information, see Blue/green deployment with // CodeDeploy // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-type-bluegreen.html) // in the Amazon Elastic Container Service Developer Guide. If your service's task @@ -2324,7 +2350,7 @@ type LogConfiguration struct { Options map[string]string // The secrets to pass to the log configuration. For more information, see - // Specifying Sensitive Data + // Specifying sensitive data // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/specifying-sensitive-data.html) // in the Amazon Elastic Container Service Developer Guide. SecretOptions []Secret @@ -2380,7 +2406,7 @@ type ManagedAgentStateChange struct { // actions of the Auto Scaling group. Amazon ECS manages a target tracking scaling // policy using an Amazon ECS managed CloudWatch metric with the specified // targetCapacity value as the target value for the metric. For more information, -// see Using Managed Scaling +// see Using managed scaling // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/asg-capacity-providers.html#asg-capacity-providers-managed-scaling) // in the Amazon Elastic Container Service Developer Guide. If managed scaling is // disabled, the user must manage the scaling of the Auto Scaling group. @@ -2477,7 +2503,7 @@ type NetworkInterface struct { } // An object representing a constraint on task placement. For more information, see -// Task Placement Constraints +// Task placement constraints // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-placement-constraints.html) // in the Amazon Elastic Container Service Developer Guide. If you're using the // Fargate launch type, task placement constraints aren't supported. @@ -2500,7 +2526,7 @@ type PlacementConstraint struct { } // The task placement strategy for a task or service. For more information, see -// Task Placement Strategies +// Task placement strategies // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-placement-strategies.html) // in the Amazon Elastic Container Service Developer Guide. type PlacementStrategy struct { @@ -2731,7 +2757,7 @@ type ResourceRequirement struct { type RuntimePlatform struct { // The CPU architecture. You can run your Linux tasks on an ARM-based platform by - // setting the value to ARM64. This option is avaiable for tasks that run on Linuc + // setting the value to ARM64. This option is avaiable for tasks that run on Linux // Amazon EC2 instance or Linux containers on Fargate. CpuArchitecture CPUArchitecture @@ -2766,7 +2792,7 @@ type Scale struct { // container, use the secretOptions container definition parameter. // // For more -// information, see Specifying Sensitive Data +// information, see Specifying sensitive data // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/specifying-sensitive-data.html) // in the Amazon Elastic Container Service Developer Guide. type Secret struct { @@ -2915,10 +2941,10 @@ type Service struct { // DAEMON scheduling strategy. SchedulingStrategy SchedulingStrategy - // The ARN that identifies the service. The ARN contains the arn:aws:ecs namespace, - // followed by the Region of the service, the Amazon Web Services account ID of the - // service owner, the service namespace, and then the service name. For example, - // arn:aws:ecs:region:012345678910:service/my-service. + // The ARN that identifies the service. For more information about the ARN format, + // see Amazon Resource Name (ARN) + // (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-account-settings.html#ecs-resource-ids) + // in the Amazon ECS Developer Guide. ServiceArn *string // The name of your service. Up to 255 letters (uppercase and lowercase), numbers, diff --git a/service/wellarchitected/api_op_CreateLensShare.go b/service/wellarchitected/api_op_CreateLensShare.go index 3f080bbcd40..1068515f7f9 100644 --- a/service/wellarchitected/api_op_CreateLensShare.go +++ b/service/wellarchitected/api_op_CreateLensShare.go @@ -48,8 +48,12 @@ type CreateLensShareInput struct { // This member is required. ClientRequestToken *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_CreateLensVersion.go b/service/wellarchitected/api_op_CreateLensVersion.go index 3ebd133b8cc..4cbdd1cb0c9 100644 --- a/service/wellarchitected/api_op_CreateLensVersion.go +++ b/service/wellarchitected/api_op_CreateLensVersion.go @@ -44,8 +44,12 @@ type CreateLensVersionInput struct { // This member is required. ClientRequestToken *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_CreateWorkload.go b/service/wellarchitected/api_op_CreateWorkload.go index 9e5efa5107a..f4e03be4e12 100644 --- a/service/wellarchitected/api_op_CreateWorkload.go +++ b/service/wellarchitected/api_op_CreateWorkload.go @@ -64,12 +64,6 @@ type CreateWorkloadInput struct { // This member is required. Lenses []string - // The review owner of the workload. The name, email address, or identifier for the - // primary group or individual that owns the workload review process. - // - // This member is required. - ReviewOwner *string - // The name of the workload. The name must be unique within an account within an // Amazon Web Services Region. Spaces and capitalization are ignored when checking // for uniqueness. @@ -165,6 +159,10 @@ type CreateWorkloadInput struct { // plan. Each pillar is represented by its PillarReviewSummary$PillarId. PillarPriorities []string + // The review owner of the workload. The name, email address, or identifier for the + // primary group or individual that owns the workload review process. + ReviewOwner *string + // The tags to be associated with the workload. Tags map[string]string diff --git a/service/wellarchitected/api_op_DeleteLens.go b/service/wellarchitected/api_op_DeleteLens.go index 4813b6740d8..66986644256 100644 --- a/service/wellarchitected/api_op_DeleteLens.go +++ b/service/wellarchitected/api_op_DeleteLens.go @@ -50,8 +50,12 @@ type DeleteLensInput struct { // This member is required. ClientRequestToken *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_DeleteLensShare.go b/service/wellarchitected/api_op_DeleteLensShare.go index a6742e28907..40b1ea1c612 100644 --- a/service/wellarchitected/api_op_DeleteLensShare.go +++ b/service/wellarchitected/api_op_DeleteLensShare.go @@ -48,8 +48,12 @@ type DeleteLensShareInput struct { // This member is required. ClientRequestToken *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_ExportLens.go b/service/wellarchitected/api_op_ExportLens.go index 30128adb7df..9d6bc92e114 100644 --- a/service/wellarchitected/api_op_ExportLens.go +++ b/service/wellarchitected/api_op_ExportLens.go @@ -37,8 +37,12 @@ func (c *Client) ExportLens(ctx context.Context, params *ExportLensInput, optFns type ExportLensInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_GetAnswer.go b/service/wellarchitected/api_op_GetAnswer.go index 802ad987a4f..59a75d2b3d6 100644 --- a/service/wellarchitected/api_op_GetAnswer.go +++ b/service/wellarchitected/api_op_GetAnswer.go @@ -30,8 +30,12 @@ func (c *Client) GetAnswer(ctx context.Context, params *GetAnswerInput, optFns . // Input to get answer. type GetAnswerInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string @@ -59,8 +63,12 @@ type GetAnswerOutput struct { // An answer of the question. Answer *types.Answer - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/api_op_GetLens.go b/service/wellarchitected/api_op_GetLens.go index f7eba104528..d2ca5120be5 100644 --- a/service/wellarchitected/api_op_GetLens.go +++ b/service/wellarchitected/api_op_GetLens.go @@ -29,8 +29,12 @@ func (c *Client) GetLens(ctx context.Context, params *GetLensInput, optFns ...fu type GetLensInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_GetLensReview.go b/service/wellarchitected/api_op_GetLensReview.go index fe680741a6f..60feeb97ad5 100644 --- a/service/wellarchitected/api_op_GetLensReview.go +++ b/service/wellarchitected/api_op_GetLensReview.go @@ -30,8 +30,12 @@ func (c *Client) GetLensReview(ctx context.Context, params *GetLensReviewInput, // Input to get lens review. type GetLensReviewInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_GetLensReviewReport.go b/service/wellarchitected/api_op_GetLensReviewReport.go index f1eb6b03e3f..089fd5a8f31 100644 --- a/service/wellarchitected/api_op_GetLensReviewReport.go +++ b/service/wellarchitected/api_op_GetLensReviewReport.go @@ -30,8 +30,12 @@ func (c *Client) GetLensReviewReport(ctx context.Context, params *GetLensReviewR // Input to get lens review report. type GetLensReviewReportInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_GetLensVersionDifference.go b/service/wellarchitected/api_op_GetLensVersionDifference.go index 8f383667003..b6f86f0432e 100644 --- a/service/wellarchitected/api_op_GetLensVersionDifference.go +++ b/service/wellarchitected/api_op_GetLensVersionDifference.go @@ -29,8 +29,12 @@ func (c *Client) GetLensVersionDifference(ctx context.Context, params *GetLensVe type GetLensVersionDifferenceInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string @@ -52,8 +56,12 @@ type GetLensVersionDifferenceOutput struct { // The latest version of the lens. LatestLensVersion *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/api_op_ImportLens.go b/service/wellarchitected/api_op_ImportLens.go index 659e305bcac..bedaf7df51f 100644 --- a/service/wellarchitected/api_op_ImportLens.go +++ b/service/wellarchitected/api_op_ImportLens.go @@ -57,8 +57,12 @@ type ImportLensInput struct { // This member is required. JSONString *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // Tags to associate to a lens. diff --git a/service/wellarchitected/api_op_ListAnswers.go b/service/wellarchitected/api_op_ListAnswers.go index 66cc4e33688..1e83a4c3b17 100644 --- a/service/wellarchitected/api_op_ListAnswers.go +++ b/service/wellarchitected/api_op_ListAnswers.go @@ -31,8 +31,12 @@ func (c *Client) ListAnswers(ctx context.Context, params *ListAnswersInput, optF // Input to list answers. type ListAnswersInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string @@ -65,8 +69,12 @@ type ListAnswersOutput struct { // List of answer summaries of lens review in a workload. AnswerSummaries []types.AnswerSummary - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/api_op_ListLensReviewImprovements.go b/service/wellarchitected/api_op_ListLensReviewImprovements.go index 563f39c7aa9..523b7cda80b 100644 --- a/service/wellarchitected/api_op_ListLensReviewImprovements.go +++ b/service/wellarchitected/api_op_ListLensReviewImprovements.go @@ -31,8 +31,12 @@ func (c *Client) ListLensReviewImprovements(ctx context.Context, params *ListLen // Input to list lens review improvements. type ListLensReviewImprovementsInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string @@ -65,8 +69,12 @@ type ListLensReviewImprovementsOutput struct { // List of improvement summaries of lens review in a workload. ImprovementSummaries []types.ImprovementSummary - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/api_op_ListLensShares.go b/service/wellarchitected/api_op_ListLensShares.go index 211564f0233..e99fbac8879 100644 --- a/service/wellarchitected/api_op_ListLensShares.go +++ b/service/wellarchitected/api_op_ListLensShares.go @@ -30,8 +30,12 @@ func (c *Client) ListLensShares(ctx context.Context, params *ListLensSharesInput type ListLensSharesInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_ListTagsForResource.go b/service/wellarchitected/api_op_ListTagsForResource.go index 154e68e0d58..bf805a09bf9 100644 --- a/service/wellarchitected/api_op_ListTagsForResource.go +++ b/service/wellarchitected/api_op_ListTagsForResource.go @@ -10,7 +10,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// List the tags for a resource. +// List the tags for a resource. The WorkloadArn parameter can be either a workload +// ARN or a custom lens ARN. func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForResourceInput, optFns ...func(*Options)) (*ListTagsForResourceOutput, error) { if params == nil { params = &ListTagsForResourceInput{} diff --git a/service/wellarchitected/api_op_TagResource.go b/service/wellarchitected/api_op_TagResource.go index 62443bd914c..f7ca1db4d78 100644 --- a/service/wellarchitected/api_op_TagResource.go +++ b/service/wellarchitected/api_op_TagResource.go @@ -10,7 +10,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Adds one or more tags to the specified resource. +// Adds one or more tags to the specified resource. The WorkloadArn parameter can +// be either a workload ARN or a custom lens ARN. func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optFns ...func(*Options)) (*TagResourceOutput, error) { if params == nil { params = &TagResourceInput{} diff --git a/service/wellarchitected/api_op_UntagResource.go b/service/wellarchitected/api_op_UntagResource.go index af8d1fd0b9e..280df1db629 100644 --- a/service/wellarchitected/api_op_UntagResource.go +++ b/service/wellarchitected/api_op_UntagResource.go @@ -10,7 +10,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Deletes specified tags from a resource. To specify multiple tags, use separate +// Deletes specified tags from a resource. The WorkloadArn parameter can be either +// a workload ARN or a custom lens ARN. To specify multiple tags, use separate // tagKeys parameters, for example: DELETE // /tags/WorkloadArn?tagKeys=key1&tagKeys=key2 func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, optFns ...func(*Options)) (*UntagResourceOutput, error) { diff --git a/service/wellarchitected/api_op_UpdateAnswer.go b/service/wellarchitected/api_op_UpdateAnswer.go index 6d54aaeed8c..7f5e127483c 100644 --- a/service/wellarchitected/api_op_UpdateAnswer.go +++ b/service/wellarchitected/api_op_UpdateAnswer.go @@ -30,8 +30,12 @@ func (c *Client) UpdateAnswer(ctx context.Context, params *UpdateAnswerInput, op // Input to update answer. type UpdateAnswerInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string @@ -73,8 +77,12 @@ type UpdateAnswerOutput struct { // An answer of the question. Answer *types.Answer - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/api_op_UpdateLensReview.go b/service/wellarchitected/api_op_UpdateLensReview.go index 5a37554b559..de83fc739ad 100644 --- a/service/wellarchitected/api_op_UpdateLensReview.go +++ b/service/wellarchitected/api_op_UpdateLensReview.go @@ -30,8 +30,12 @@ func (c *Client) UpdateLensReview(ctx context.Context, params *UpdateLensReviewI // Input for update lens review. type UpdateLensReviewInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/api_op_UpgradeLensReview.go b/service/wellarchitected/api_op_UpgradeLensReview.go index f3b0d547ad8..59fad8ada3b 100644 --- a/service/wellarchitected/api_op_UpgradeLensReview.go +++ b/service/wellarchitected/api_op_UpgradeLensReview.go @@ -28,8 +28,12 @@ func (c *Client) UpgradeLensReview(ctx context.Context, params *UpgradeLensRevie type UpgradeLensReviewInput struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. // // This member is required. LensAlias *string diff --git a/service/wellarchitected/deserializers.go b/service/wellarchitected/deserializers.go index aea4464e9a8..cec99c021ca 100644 --- a/service/wellarchitected/deserializers.go +++ b/service/wellarchitected/deserializers.go @@ -6479,6 +6479,85 @@ func awsRestjson1_deserializeDocumentAccessDeniedException(v **types.AccessDenie return nil } +func awsRestjson1_deserializeDocumentAdditionalResources(v **types.AdditionalResources, 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.AdditionalResources + if *v == nil { + sv = &types.AdditionalResources{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Content": + if err := awsRestjson1_deserializeDocumentUrls(&sv.Content, value); err != nil { + return err + } + + case "Type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected AdditionalResourceType to be of type string, got %T instead", value) + } + sv.Type = types.AdditionalResourceType(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentAdditionalResourcesList(v *[]types.AdditionalResources, 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.AdditionalResources + if *v == nil { + cv = []types.AdditionalResources{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.AdditionalResources + destAddr := &col + if err := awsRestjson1_deserializeDocumentAdditionalResources(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentAnswer(v **types.Answer, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -6780,6 +6859,11 @@ func awsRestjson1_deserializeDocumentChoice(v **types.Choice, value interface{}) for key, value := range shape { switch key { + case "AdditionalResources": + if err := awsRestjson1_deserializeDocumentAdditionalResourcesList(&sv.AdditionalResources, value); err != nil { + return err + } + case "ChoiceId": if value != nil { jtv, ok := value.(string) @@ -7483,6 +7567,11 @@ func awsRestjson1_deserializeDocumentLens(v **types.Lens, value interface{}) err sv.ShareInvitationId = ptr.String(jtv) } + case "Tags": + if err := awsRestjson1_deserializeDocumentTagMap(&sv.Tags, value); err != nil { + return err + } + default: _, _ = key, value @@ -9220,6 +9309,40 @@ func awsRestjson1_deserializeDocumentThrottlingException(v **types.ThrottlingExc return nil } +func awsRestjson1_deserializeDocumentUrls(v *[]types.ChoiceContent, 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.ChoiceContent + if *v == nil { + cv = []types.ChoiceContent{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ChoiceContent + destAddr := &col + if err := awsRestjson1_deserializeDocumentChoiceContent(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentValidationException(v **types.ValidationException, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/wellarchitected/types/enums.go b/service/wellarchitected/types/enums.go index bff40a2a1fb..b281dc38360 100644 --- a/service/wellarchitected/types/enums.go +++ b/service/wellarchitected/types/enums.go @@ -2,6 +2,24 @@ package types +type AdditionalResourceType string + +// Enum values for AdditionalResourceType +const ( + AdditionalResourceTypeHelpfulResource AdditionalResourceType = "HELPFUL_RESOURCE" + AdditionalResourceTypeImprovementPlan AdditionalResourceType = "IMPROVEMENT_PLAN" +) + +// Values returns all known values for AdditionalResourceType. 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 (AdditionalResourceType) Values() []AdditionalResourceType { + return []AdditionalResourceType{ + "HELPFUL_RESOURCE", + "IMPROVEMENT_PLAN", + } +} + type AnswerReason string // Enum values for AnswerReason diff --git a/service/wellarchitected/types/types.go b/service/wellarchitected/types/types.go index c07071893fe..73b68e21dae 100644 --- a/service/wellarchitected/types/types.go +++ b/service/wellarchitected/types/types.go @@ -7,6 +7,19 @@ import ( "time" ) +// The choice level additional resources. +type AdditionalResources struct { + + // The URLs for additional resources, either helpful resources or improvement + // plans. Up to five additional URLs can be specified. + Content []ChoiceContent + + // Type of additional resource. + Type AdditionalResourceType + + noSmithyDocumentSerde +} + // An answer of the question. type Answer struct { @@ -96,6 +109,10 @@ type AnswerSummary struct { // A choice available to answer question. type Choice struct { + // The additional resources for a choice. A choice can have up to two additional + // resources: one of type HELPFUL_RESOURCE, one of type IMPROVEMENT_PLAN, or both. + AdditionalResources []AdditionalResources + // The ID of a choice. ChoiceId *string @@ -239,14 +256,21 @@ type Lens struct { // The ID assigned to the share invitation. ShareInvitationId *string + // The tags assigned to the lens. + Tags map[string]string + noSmithyDocumentSerde } // A lens review of a question. type LensReview struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. @@ -286,8 +310,12 @@ type LensReviewReport struct { // be used to create a PDF file. Base64String *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. @@ -299,8 +327,12 @@ type LensReviewReport struct { // A lens review summary of a workload. type LensReviewSummary struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. @@ -349,8 +381,12 @@ type LensSummary struct { // The description of the lens. Description *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN of the lens. @@ -386,8 +422,12 @@ type LensUpgradeSummary struct { // The latest version of the lens. LatestLensVersion *string - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. @@ -511,8 +551,12 @@ type QuestionDifference struct { // The share invitation. type ShareInvitation struct { - // The alias of the lens, for example, serverless. Each lens is identified by its - // LensSummary$LensAlias. + // The alias of the lens. For Amazon Web Services official lenses, this is either + // the lens alias, such as serverless, or the lens ARN, such as + // arn:aws:wellarchitected:us-west-2::lens/serverless. For custom lenses, this is + // the lens ARN, such as + // arn:aws:wellarchitected:us-east-1:123456789012:lens/my-lens. Each lens is + // identified by its LensSummary$LensAlias. LensAlias *string // The ARN for the lens. diff --git a/service/wellarchitected/validators.go b/service/wellarchitected/validators.go index 3d77210414f..3bd33386bdb 100644 --- a/service/wellarchitected/validators.go +++ b/service/wellarchitected/validators.go @@ -978,9 +978,6 @@ func validateOpCreateWorkloadInput(v *CreateWorkloadInput) error { if len(v.Environment) == 0 { invalidParams.Add(smithy.NewErrParamRequired("Environment")) } - if v.ReviewOwner == nil { - invalidParams.Add(smithy.NewErrParamRequired("ReviewOwner")) - } if v.Lenses == nil { invalidParams.Add(smithy.NewErrParamRequired("Lenses")) }