From ff5b1c7a27c061145c37e8169a285a91a2aabc6c Mon Sep 17 00:00:00 2001 From: AWS SDK for Go v2 automation user Date: Wed, 4 Jan 2023 19:14:42 +0000 Subject: [PATCH] Regenerated Clients --- .../58bc4bc08fdc4715ae6b115784cd43b3.json | 8 ++ .../84209f3f671245978af16b4293d1621e.json | 8 ++ .../a11cacfc5ec24c7b92c1d5fb8745814f.json | 8 ++ .../api_op_DeleteScalingPolicy.go | 2 +- .../api_op_DeleteScheduledAction.go | 2 +- .../api_op_DeregisterScalableTarget.go | 2 +- .../api_op_DescribeScalableTargets.go | 2 +- .../api_op_DescribeScalingActivities.go | 15 ++- .../api_op_DescribeScalingPolicies.go | 2 +- .../api_op_DescribeScheduledActions.go | 2 +- .../api_op_PutScalingPolicy.go | 17 +-- .../api_op_PutScheduledAction.go | 2 +- .../api_op_RegisterScalableTarget.go | 61 ++++++--- .../applicationautoscaling/deserializers.go | 118 ++++++++++++++++++ service/applicationautoscaling/serializers.go | 5 + service/applicationautoscaling/types/types.go | 111 ++++++++++++---- .../api_op_PutDestinationPolicy.go | 5 +- service/cloudwatchlogs/api_op_PutLogEvents.go | 77 ++++++------ service/cloudwatchlogs/types/errors.go | 6 +- service/cloudwatchlogs/types/types.go | 9 +- service/ssm/api_op_UpdateAssociation.go | 10 +- service/ssm/deserializers.go | 18 +++ service/ssm/serializers.go | 10 ++ service/ssm/types/enums.go | 2 + service/ssm/types/types.go | 8 ++ 25 files changed, 402 insertions(+), 108 deletions(-) create mode 100644 .changelog/58bc4bc08fdc4715ae6b115784cd43b3.json create mode 100644 .changelog/84209f3f671245978af16b4293d1621e.json create mode 100644 .changelog/a11cacfc5ec24c7b92c1d5fb8745814f.json diff --git a/.changelog/58bc4bc08fdc4715ae6b115784cd43b3.json b/.changelog/58bc4bc08fdc4715ae6b115784cd43b3.json new file mode 100644 index 00000000000..b5a61bc23ba --- /dev/null +++ b/.changelog/58bc4bc08fdc4715ae6b115784cd43b3.json @@ -0,0 +1,8 @@ +{ + "id": "58bc4bc0-8fdc-4715-ae6b-115784cd43b3", + "type": "documentation", + "description": "Update to remove sequenceToken as a required field in PutLogEvents calls.", + "modules": [ + "service/cloudwatchlogs" + ] +} \ No newline at end of file diff --git a/.changelog/84209f3f671245978af16b4293d1621e.json b/.changelog/84209f3f671245978af16b4293d1621e.json new file mode 100644 index 00000000000..8de24e6c924 --- /dev/null +++ b/.changelog/84209f3f671245978af16b4293d1621e.json @@ -0,0 +1,8 @@ +{ + "id": "84209f3f-6712-4597-8af1-6b4293d1621e", + "type": "feature", + "description": "Adding support for QuickSetup Document Type in Systems Manager", + "modules": [ + "service/ssm" + ] +} \ No newline at end of file diff --git a/.changelog/a11cacfc5ec24c7b92c1d5fb8745814f.json b/.changelog/a11cacfc5ec24c7b92c1d5fb8745814f.json new file mode 100644 index 00000000000..52cada00c30 --- /dev/null +++ b/.changelog/a11cacfc5ec24c7b92c1d5fb8745814f.json @@ -0,0 +1,8 @@ +{ + "id": "a11cacfc-5ec2-4c7b-92c1-d5fb8745814f", + "type": "feature", + "description": "Customers can now use the existing DescribeScalingActivities API to also see the detailed and machine-readable reasons for Application Auto Scaling not scaling their resources and, if needed, take the necessary corrective actions.", + "modules": [ + "service/applicationautoscaling" + ] +} \ No newline at end of file diff --git a/service/applicationautoscaling/api_op_DeleteScalingPolicy.go b/service/applicationautoscaling/api_op_DeleteScalingPolicy.go index ffc0bfffd31..a7e884dfd6a 100644 --- a/service/applicationautoscaling/api_op_DeleteScalingPolicy.go +++ b/service/applicationautoscaling/api_op_DeleteScalingPolicy.go @@ -154,7 +154,7 @@ type DeleteScalingPolicyInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_DeleteScheduledAction.go b/service/applicationautoscaling/api_op_DeleteScheduledAction.go index eb649f80b79..50b4fdba796 100644 --- a/service/applicationautoscaling/api_op_DeleteScheduledAction.go +++ b/service/applicationautoscaling/api_op_DeleteScheduledAction.go @@ -144,7 +144,7 @@ type DeleteScheduledActionInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_DeregisterScalableTarget.go b/service/applicationautoscaling/api_op_DeregisterScalableTarget.go index df2d41ec2a8..a477a4a38dc 100644 --- a/service/applicationautoscaling/api_op_DeregisterScalableTarget.go +++ b/service/applicationautoscaling/api_op_DeregisterScalableTarget.go @@ -147,7 +147,7 @@ type DeregisterScalableTargetInput struct { // PostgreSQL-compatible edition. // // * sagemaker:variant:DesiredInstanceCount - The - // number of EC2 instances for an SageMaker model endpoint variant. + // number of EC2 instances for a SageMaker model endpoint variant. // // * // custom-resource:ResourceType:Property - The scalable dimension for a custom diff --git a/service/applicationautoscaling/api_op_DescribeScalableTargets.go b/service/applicationautoscaling/api_op_DescribeScalableTargets.go index e26f9ab4198..20f176c0735 100644 --- a/service/applicationautoscaling/api_op_DescribeScalableTargets.go +++ b/service/applicationautoscaling/api_op_DescribeScalableTargets.go @@ -161,7 +161,7 @@ type DescribeScalableTargetsInput struct { // PostgreSQL-compatible edition. // // * sagemaker:variant:DesiredInstanceCount - The - // number of EC2 instances for an SageMaker model endpoint variant. + // number of EC2 instances for a SageMaker model endpoint variant. // // * // custom-resource:ResourceType:Property - The scalable dimension for a custom diff --git a/service/applicationautoscaling/api_op_DescribeScalingActivities.go b/service/applicationautoscaling/api_op_DescribeScalingActivities.go index 32fd39969be..fb63e945eeb 100644 --- a/service/applicationautoscaling/api_op_DescribeScalingActivities.go +++ b/service/applicationautoscaling/api_op_DescribeScalingActivities.go @@ -14,7 +14,10 @@ import ( // Provides descriptive information about the scaling activities in the specified // namespace from the previous six weeks. You can filter the results using -// ResourceId and ScalableDimension. +// ResourceId and ScalableDimension. For information about viewing scaling +// activities using the Amazon Web Services CLI, see Scaling activities for +// Application Auto Scaling +// (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scaling-activities.html). func (c *Client) DescribeScalingActivities(ctx context.Context, params *DescribeScalingActivitiesInput, optFns ...func(*Options)) (*DescribeScalingActivitiesOutput, error) { if params == nil { params = &DescribeScalingActivitiesInput{} @@ -39,6 +42,14 @@ type DescribeScalingActivitiesInput struct { // This member is required. ServiceNamespace types.ServiceNamespace + // Specifies whether to include activities that aren't scaled (not scaled + // activities) in the response. Not scaled activities are activities that aren't + // completed or started for various reasons, such as preventing infinite scaling + // loops. For help interpreting the not scaled reason details in the response, see + // Scaling activities for Application Auto Scaling + // (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scaling-activities.html). + IncludeNotScaledActivities *bool + // The maximum number of scalable targets. This value can be between 1 and 50. The // default value is 50. If this parameter is used, the operation returns up to // MaxResults results at a time, along with a NextToken value. To get the next set @@ -161,7 +172,7 @@ type DescribeScalingActivitiesInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_DescribeScalingPolicies.go b/service/applicationautoscaling/api_op_DescribeScalingPolicies.go index 09184bf6560..894bfe2856e 100644 --- a/service/applicationautoscaling/api_op_DescribeScalingPolicies.go +++ b/service/applicationautoscaling/api_op_DescribeScalingPolicies.go @@ -169,7 +169,7 @@ type DescribeScalingPoliciesInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_DescribeScheduledActions.go b/service/applicationautoscaling/api_op_DescribeScheduledActions.go index 0acb97975a4..52781e8eb6b 100644 --- a/service/applicationautoscaling/api_op_DescribeScheduledActions.go +++ b/service/applicationautoscaling/api_op_DescribeScheduledActions.go @@ -166,7 +166,7 @@ type DescribeScheduledActionsInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_PutScalingPolicy.go b/service/applicationautoscaling/api_op_PutScalingPolicy.go index d4f8677c244..405cbd7d2fe 100644 --- a/service/applicationautoscaling/api_op_PutScalingPolicy.go +++ b/service/applicationautoscaling/api_op_PutScalingPolicy.go @@ -56,7 +56,9 @@ func (c *Client) PutScalingPolicy(ctx context.Context, params *PutScalingPolicyI type PutScalingPolicyInput struct { - // The name of the scaling policy. + // The name of the scaling policy. You cannot change the name of a scaling policy, + // but you can delete the original scaling policy and create a new scaling policy + // with the same settings and a different name. // // This member is required. PolicyName *string @@ -173,7 +175,7 @@ type PutScalingPolicyInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The @@ -222,11 +224,12 @@ type PutScalingPolicyInput struct { // This member is required. ServiceNamespace types.ServiceNamespace - // The policy type. This parameter is required if you are creating a scaling - // policy. The following policy types are supported: TargetTrackingScaling—Not - // supported for Amazon EMR StepScaling—Not supported for DynamoDB, Amazon - // Comprehend, Lambda, Amazon Keyspaces, Amazon MSK, Amazon ElastiCache, or - // Neptune. For more information, see Target tracking scaling policies + // The scaling policy type. This parameter is required if you are creating a + // scaling policy. The following policy types are supported: + // TargetTrackingScaling—Not supported for Amazon EMR StepScaling—Not supported for + // DynamoDB, Amazon Comprehend, Lambda, Amazon Keyspaces, Amazon MSK, Amazon + // ElastiCache, or Neptune. For more information, see Target tracking scaling + // policies // (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-target-tracking.html) // and Step scaling policies // (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-step-scaling-policies.html) diff --git a/service/applicationautoscaling/api_op_PutScheduledAction.go b/service/applicationautoscaling/api_op_PutScheduledAction.go index 945f8140b1b..51a1144225f 100644 --- a/service/applicationautoscaling/api_op_PutScheduledAction.go +++ b/service/applicationautoscaling/api_op_PutScheduledAction.go @@ -156,7 +156,7 @@ type PutScheduledActionInput struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The diff --git a/service/applicationautoscaling/api_op_RegisterScalableTarget.go b/service/applicationautoscaling/api_op_RegisterScalableTarget.go index 11b593d5718..2daefe86e8e 100644 --- a/service/applicationautoscaling/api_op_RegisterScalableTarget.go +++ b/service/applicationautoscaling/api_op_RegisterScalableTarget.go @@ -11,16 +11,20 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Registers or updates a scalable target. A scalable target is a resource that -// Application Auto Scaling can scale out and scale in. Scalable targets are -// uniquely identified by the combination of resource ID, scalable dimension, and -// namespace. When you register a new scalable target, you must specify values for -// minimum and maximum capacity. Current capacity will be adjusted within the -// specified range when scaling starts. Application Auto Scaling scaling policies -// will not scale capacity to values that are outside of this range. After you -// register a scalable target, you do not need to register it again to use other -// Application Auto Scaling operations. To see which resources have been -// registered, use DescribeScalableTargets +// Registers or updates a scalable target, the resource that you want to scale. +// Scalable targets are uniquely identified by the combination of resource ID, +// scalable dimension, and namespace, which represents some capacity dimension of +// the underlying service. When you register a new scalable target, you must +// specify values for the minimum and maximum capacity. If the specified resource +// is not active in the target service, this operation does not change the +// resource's current capacity. Otherwise, it changes the resource's current +// capacity to a value that is inside of this range. If you choose to add a scaling +// policy, current capacity is adjustable within the specified range when scaling +// starts. Application Auto Scaling scaling policies will not scale capacity to +// values that are outside of the minimum and maximum range. After you register a +// scalable target, you do not need to register it again to use other Application +// Auto Scaling operations. To see which resources have been registered, use +// DescribeScalableTargets // (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_DescribeScalableTargets.html). // You can also view the scaling policies for a service namespace by using // DescribeScalableTargets @@ -167,7 +171,7 @@ type RegisterScalableTargetInput struct { // PostgreSQL-compatible edition. // // * sagemaker:variant:DesiredInstanceCount - The - // number of EC2 instances for an SageMaker model endpoint variant. + // number of EC2 instances for a SageMaker model endpoint variant. // // * // custom-resource:ResourceType:Property - The scalable dimension for a custom @@ -223,7 +227,7 @@ type RegisterScalableTargetInput struct { // own default quotas for the maximum capacity of the resource. If you want to // specify a higher limit, you can request an increase. For more information, // consult the documentation for that service. For information about the default - // quotas for each service, see Service Endpoints and Quotas + // quotas for each service, see Service endpoints and quotas // (https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html) in // the Amazon Web Services General Reference. MaxCapacity *int32 @@ -231,10 +235,35 @@ type RegisterScalableTargetInput struct { // The minimum value that you plan to scale in to. When a scaling policy is in // effect, Application Auto Scaling can scale in (contract) as needed to the // minimum capacity limit in response to changing demand. This property is required - // when registering a new scalable target. For certain resources, the minimum value - // allowed is 0. This includes Lambda provisioned concurrency, Spot Fleet, ECS - // services, Aurora DB clusters, EMR clusters, and custom resources. For all other - // resources, the minimum value allowed is 1. + // when registering a new scalable target. For the following resources, the minimum + // value allowed is 0. + // + // * AppStream 2.0 fleets + // + // * Aurora DB clusters + // + // * ECS + // services + // + // * EMR clusters + // + // * Lambda provisioned concurrency + // + // * SageMaker endpoint + // variants + // + // * Spot Fleets + // + // * custom resources + // + // It's strongly recommended that you + // specify a value greater than 0. A value greater than 0 means that data points + // are continuously reported to CloudWatch that scaling policies can use to scale + // on a metric like average CPU utilization. For all other resources, the minimum + // allowed value depends on the type of resource that you are using. If you provide + // a value that is lower than what a resource can accept, an error occurs. In which + // case, the error message will provide the minimum value that the resource can + // accept. MinCapacity *int32 // This parameter is required for services that do not support service-linked roles diff --git a/service/applicationautoscaling/deserializers.go b/service/applicationautoscaling/deserializers.go index 34107098db1..25b4869878e 100644 --- a/service/applicationautoscaling/deserializers.go +++ b/service/applicationautoscaling/deserializers.go @@ -1915,6 +1915,119 @@ func awsAwsjson11_deserializeDocumentMetricDimensions(v *[]types.MetricDimension return nil } +func awsAwsjson11_deserializeDocumentNotScaledReason(v **types.NotScaledReason, 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.NotScaledReason + if *v == nil { + sv = &types.NotScaledReason{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Code": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected XmlString to be of type string, got %T instead", value) + } + sv.Code = ptr.String(jtv) + } + + case "CurrentCapacity": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ResourceCapacity to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.CurrentCapacity = ptr.Int32(int32(i64)) + } + + case "MaxCapacity": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ResourceCapacity to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.MaxCapacity = ptr.Int32(int32(i64)) + } + + case "MinCapacity": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ResourceCapacity to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.MinCapacity = ptr.Int32(int32(i64)) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson11_deserializeDocumentNotScaledReasons(v *[]types.NotScaledReason, 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.NotScaledReason + if *v == nil { + cv = []types.NotScaledReason{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.NotScaledReason + destAddr := &col + if err := awsAwsjson11_deserializeDocumentNotScaledReason(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsAwsjson11_deserializeDocumentObjectNotFoundException(v **types.ObjectNotFoundException, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -2317,6 +2430,11 @@ func awsAwsjson11_deserializeDocumentScalingActivity(v **types.ScalingActivity, } } + case "NotScaledReasons": + if err := awsAwsjson11_deserializeDocumentNotScaledReasons(&sv.NotScaledReasons, value); err != nil { + return err + } + case "ResourceId": if value != nil { jtv, ok := value.(string) diff --git a/service/applicationautoscaling/serializers.go b/service/applicationautoscaling/serializers.go index 70806f4f521..64f760aadb6 100644 --- a/service/applicationautoscaling/serializers.go +++ b/service/applicationautoscaling/serializers.go @@ -960,6 +960,11 @@ func awsAwsjson11_serializeOpDocumentDescribeScalingActivitiesInput(v *DescribeS object := value.Object() defer object.Close() + if v.IncludeNotScaledActivities != nil { + ok := object.Key("IncludeNotScaledActivities") + ok.Boolean(*v.IncludeNotScaledActivities) + } + if v.MaxResults != nil { ok := object.Key("MaxResults") ok.Integer(*v.MaxResults) diff --git a/service/applicationautoscaling/types/types.go b/service/applicationautoscaling/types/types.go index 9398792ce58..0215787e65e 100644 --- a/service/applicationautoscaling/types/types.go +++ b/service/applicationautoscaling/types/types.go @@ -25,8 +25,8 @@ type Alarm struct { // Represents a CloudWatch metric of your choosing for a target tracking scaling // policy to use with Application Auto Scaling. For information about the available -// metrics for a service, see Amazon Web Services Services That Publish CloudWatch -// Metrics +// metrics for a service, see Amazon Web Services services that publish CloudWatch +// metrics // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/aws-services-cloudwatch-metrics.html) // in the Amazon CloudWatch User Guide. To create your customized metric // specification: @@ -34,7 +34,7 @@ type Alarm struct { // * Add values for each required parameter from CloudWatch. You // can use an existing metric, or a new metric that you create. To use your own // metric, you must first publish the metric to CloudWatch. For more information, -// see Publish Custom Metrics +// see Publish custom metrics // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/publishingMetrics.html) // in the Amazon CloudWatch User Guide. // @@ -44,12 +44,23 @@ type Alarm struct { // value of the metric should decrease when capacity increases, and increase when // capacity decreases. // -// For more information about CloudWatch, see Amazon -// CloudWatch Concepts -// (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html). +// For an example of how creating new metrics can be useful, +// see Scaling based on Amazon SQS +// (https://docs.aws.amazon.com/autoscaling/ec2/userguide/as-using-sqs-queue.html) +// in the Amazon EC2 Auto Scaling User Guide. This topic mentions Auto Scaling +// groups, but the same scenario for Amazon SQS can apply to the target tracking +// scaling policies that you create for a Spot Fleet by using the Application Auto +// Scaling API. For more information about the CloudWatch terminology below, see +// Amazon CloudWatch concepts +// (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html) +// in the Amazon CloudWatch User Guide. type CustomizedMetricSpecification struct { - // The name of the metric. + // The name of the metric. To get the exact metric name, namespace, and dimensions, + // inspect the Metric + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html) + // object that is returned by a call to ListMetrics + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html). // // This member is required. MetricName *string @@ -68,7 +79,10 @@ type CustomizedMetricSpecification struct { // dimensions, you must specify the same dimensions in your scaling policy. Dimensions []MetricDimension - // The unit of the metric. + // The unit of the metric. For a complete list of the units that CloudWatch + // supports, see the MetricDatum + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html) + // data type in the Amazon CloudWatch API Reference. Unit *string noSmithyDocumentSerde @@ -90,6 +104,41 @@ type MetricDimension struct { noSmithyDocumentSerde } +// Describes the reason for an activity that isn't scaled (not scaled activity), in +// machine-readable format. For help interpreting the not scaled reason details, +// see Scaling activities for Application Auto Scaling +// (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scaling-activities.html). +type NotScaledReason struct { + + // A code that represents the reason for not scaling. Valid values: + // + // * + // AutoScalingAnticipatedFlapping + // + // * TargetServicePutResourceAsUnscalable + // + // * + // AlreadyAtMaxCapacity + // + // * AlreadyAtMinCapacity + // + // * AlreadyAtDesiredCapacity + // + // This member is required. + Code *string + + // The current capacity. + CurrentCapacity *int32 + + // The maximum capacity. + MaxCapacity *int32 + + // The minimum capacity. + MinCapacity *int32 + + noSmithyDocumentSerde +} + // Represents a predefined metric for a target tracking scaling policy to use with // Application Auto Scaling. Only the Amazon Web Services that you're using send // metrics to Amazon CloudWatch. To determine whether a desired metric already @@ -101,17 +150,17 @@ type MetricDimension struct { type PredefinedMetricSpecification struct { // The metric type. The ALBRequestCountPerTarget metric type applies only to Spot - // Fleet requests and ECS services. + // Fleets and ECS services. // // This member is required. PredefinedMetricType MetricType // Identifies the resource associated with the metric type. You can't specify a // resource label unless the metric type is ALBRequestCountPerTarget and there is a - // target group attached to the Spot Fleet request or ECS service. You create the - // resource label by appending the final portion of the load balancer ARN and the - // final portion of the target group ARN into a single value, separated by a - // forward slash (/). The format of the resource label is: + // target group attached to the Spot Fleet or ECS service. You create the resource + // label by appending the final portion of the load balancer ARN and the final + // portion of the target group ARN into a single value, separated by a forward + // slash (/). The format of the resource label is: // app/my-alb/778d41231b141a0f/targetgroup/my-alb-target-group/943f017f100becff. // Where: // @@ -269,7 +318,7 @@ type ScalableTarget struct { // PostgreSQL-compatible edition. // // * sagemaker:variant:DesiredInstanceCount - The - // number of EC2 instances for an SageMaker model endpoint variant. + // number of EC2 instances for a SageMaker model endpoint variant. // // * // custom-resource:ResourceType:Property - The scalable dimension for a custom @@ -331,15 +380,14 @@ type ScalableTargetAction struct { // quotas for the maximum capacity of the resource. If you want to specify a higher // limit, you can request an increase. For more information, consult the // documentation for that service. For information about the default quotas for - // each service, see Service Endpoints and Quotas + // each service, see Service endpoints and quotas // (https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html) in // the Amazon Web Services General Reference. MaxCapacity *int32 - // The minimum capacity. For certain resources, the minimum value allowed is 0. - // This includes Lambda provisioned concurrency, Spot Fleet, ECS services, Aurora - // DB clusters, EMR clusters, and custom resources. For all other resources, the - // minimum value allowed is 1. + // The minimum capacity. When the scheduled action runs, the resource will have at + // least this much capacity, but it might have more depending on other settings, + // such as the target utilization level of a target tracking scaling policy. MinCapacity *int32 noSmithyDocumentSerde @@ -475,7 +523,7 @@ type ScalingActivity struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The @@ -539,6 +587,12 @@ type ScalingActivity struct { // The Unix timestamp for when the scaling activity ended. EndTime *time.Time + // Machine-readable data that describes the reason for a not scaled activity. Only + // available when DescribeScalingActivities + // (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_DescribeScalingActivities.html) + // includes not scaled activities. + NotScaledReasons []NotScaledReason + // A simple message about the current status of the scaling activity. StatusMessage *string @@ -547,8 +601,8 @@ type ScalingActivity struct { // Represents a scaling policy to use with Application Auto Scaling. For more // information about configuring scaling policies for a specific service, see -// Getting started with Application Auto Scaling -// (https://docs.aws.amazon.com/autoscaling/application/userguide/getting-started.html) +// Amazon Web Services services that you can use with Application Auto Scaling +// (https://docs.aws.amazon.com/autoscaling/application/userguide/integrated-services-list.html) // in the Application Auto Scaling User Guide. type ScalingPolicy struct { @@ -567,7 +621,10 @@ type ScalingPolicy struct { // This member is required. PolicyName *string - // The scaling policy type. + // The scaling policy type. The following policy types are supported: + // TargetTrackingScaling—Not supported for Amazon EMR StepScaling—Not supported for + // DynamoDB, Amazon Comprehend, Lambda, Amazon Keyspaces, Amazon MSK, Amazon + // ElastiCache, or Neptune. // // This member is required. PolicyType PolicyType @@ -684,7 +741,7 @@ type ScalingPolicy struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The @@ -908,7 +965,7 @@ type ScheduledAction struct { // edition and Aurora PostgreSQL-compatible edition. // // * - // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for an + // sagemaker:variant:DesiredInstanceCount - The number of EC2 instances for a // SageMaker model endpoint variant. // // * custom-resource:ResourceType:Property - The @@ -1145,7 +1202,9 @@ type TargetTrackingScalingPolicyConfiguration struct { // must be in the range of -2^360 to 2^360. The value must be a valid number based // on the choice of metric. For example, if the metric is CPU utilization, then the // target value is a percent value that represents how much of the CPU can be used - // before scaling out. + // before scaling out. If the scaling policy specifies the ALBRequestCountPerTarget + // predefined metric, specify the target utilization as the optimal average request + // count per target during any one-minute interval. // // This member is required. TargetValue *float64 diff --git a/service/cloudwatchlogs/api_op_PutDestinationPolicy.go b/service/cloudwatchlogs/api_op_PutDestinationPolicy.go index d5c67b03c85..7991a7a1c0c 100644 --- a/service/cloudwatchlogs/api_op_PutDestinationPolicy.go +++ b/service/cloudwatchlogs/api_op_PutDestinationPolicy.go @@ -14,10 +14,7 @@ import ( // access policy is an IAM policy document // (https://docs.aws.amazon.com/IAM/latest/UserGuide/policies_overview.html) that // is used to authorize claims to register a subscription filter against a given -// destination. If multiple Amazon Web Services accounts are sending logs to this -// destination, each sender account must be listed separately in the policy. The -// policy does not support specifying * as the Principal or the use of the -// aws:PrincipalOrgId global key. +// destination. func (c *Client) PutDestinationPolicy(ctx context.Context, params *PutDestinationPolicyInput, optFns ...func(*Options)) (*PutDestinationPolicyOutput, error) { if params == nil { params = &PutDestinationPolicyInput{} diff --git a/service/cloudwatchlogs/api_op_PutLogEvents.go b/service/cloudwatchlogs/api_op_PutLogEvents.go index 8e6893e8735..e473098f623 100644 --- a/service/cloudwatchlogs/api_op_PutLogEvents.go +++ b/service/cloudwatchlogs/api_op_PutLogEvents.go @@ -11,46 +11,45 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Uploads a batch of log events to the specified log stream. You must include the -// sequence token obtained from the response of the previous call. An upload in a -// newly created log stream does not require a sequence token. You can also get the -// sequence token in the expectedSequenceToken field from -// InvalidSequenceTokenException. If you call PutLogEvents twice within a narrow -// time period using the same value for sequenceToken, both calls might be -// successful or one might be rejected. The batch of events must satisfy the -// following constraints: +// Uploads a batch of log events to the specified log stream. The sequence token is +// now ignored in PutLogEvents actions. PutLogEvents actions are always accepted +// and never return InvalidSequenceTokenException or DataAlreadyAcceptedException +// even if the sequence token is not valid. You can use parallel PutLogEvents +// actions on the same log stream. The batch of events must satisfy the following +// constraints: // -// * The maximum batch size is 1,048,576 bytes. This size -// is calculated as the sum of all event messages in UTF-8, plus 26 bytes for each -// log event. +// * The maximum batch size is 1,048,576 bytes. This size is +// calculated as the sum of all event messages in UTF-8, plus 26 bytes for each log +// event. // -// * None of the log events in the batch can be more than 2 hours in -// the future. +// * None of the log events in the batch can be more than 2 hours in the +// future. // -// * None of the log events in the batch can be more than 14 days in -// the past. Also, none of the log events can be from earlier than the retention -// period of the log group. +// * None of the log events in the batch can be more than 14 days in the +// past. Also, none of the log events can be from earlier than the retention period +// of the log group. // -// * The log events in the batch must be in chronological -// order by their timestamp. The timestamp is the time that the event occurred, -// expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. (In -// Amazon Web Services Tools for PowerShell and the Amazon Web Services SDK for -// .NET, the timestamp is specified in .NET format: yyyy-mm-ddThh:mm:ss. For -// example, 2017-09-15T13:45:30.) +// * The log events in the batch must be in chronological order +// by their timestamp. The timestamp is the time that the event occurred, expressed +// as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. (In Amazon Web +// Services Tools for PowerShell and the Amazon Web Services SDK for .NET, the +// timestamp is specified in .NET format: yyyy-mm-ddThh:mm:ss. For example, +// 2017-09-15T13:45:30.) // -// * A batch of log events in a single request -// cannot span more than 24 hours. Otherwise, the operation fails. +// * A batch of log events in a single request cannot span +// more than 24 hours. Otherwise, the operation fails. // -// * The maximum -// number of log events in a batch is 10,000. +// * The maximum number of log +// events in a batch is 10,000. // -// * There is a quota of five requests -// per second per log stream. Additional requests are throttled. This quota can't -// be changed. +// * The quota of five requests per second per log +// stream has been removed. Instead, PutLogEvents actions are throttled based on a +// per-second per-account quota. You can request an increase to the per-second +// throttling quota by using the Service Quotas service. // -// If a call to PutLogEvents returns "UnrecognizedClientException" the -// most likely cause is a non-valid Amazon Web Services access key ID or secret -// key. +// If a call to PutLogEvents +// returns "UnrecognizedClientException" the most likely cause is a non-valid +// Amazon Web Services access key ID or secret key. func (c *Client) PutLogEvents(ctx context.Context, params *PutLogEventsInput, optFns ...func(*Options)) (*PutLogEventsOutput, error) { if params == nil { params = &PutLogEventsInput{} @@ -84,11 +83,9 @@ type PutLogEventsInput struct { LogStreamName *string // The sequence token obtained from the response of the previous PutLogEvents call. - // An upload in a newly created log stream does not require a sequence token. You - // can also get the sequence token using DescribeLogStreams - // (https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_DescribeLogStreams.html). - // If you call PutLogEvents twice within a narrow time period using the same value - // for sequenceToken, both calls might be successful or one might be rejected. + // The sequenceToken parameter is now ignored in PutLogEvents actions. PutLogEvents + // actions are now accepted and never return InvalidSequenceTokenException or + // DataAlreadyAcceptedException even if the sequence token is not valid. SequenceToken *string noSmithyDocumentSerde @@ -96,7 +93,11 @@ type PutLogEventsInput struct { type PutLogEventsOutput struct { - // The next sequence token. + // The next sequence token. This field has been deprecated. The sequence token is + // now ignored in PutLogEvents actions. PutLogEvents actions are always accepted + // even if the sequence token is not valid. You can use parallel PutLogEvents + // actions on the same log stream and you do not need to wait for the response of a + // previous PutLogEvents action to obtain the nextSequenceToken value. NextSequenceToken *string // The rejected events. diff --git a/service/cloudwatchlogs/types/errors.go b/service/cloudwatchlogs/types/errors.go index a83f9c25942..640c7004b8f 100644 --- a/service/cloudwatchlogs/types/errors.go +++ b/service/cloudwatchlogs/types/errors.go @@ -7,7 +7,9 @@ import ( smithy "github.com/aws/smithy-go" ) -// The event was already logged. +// The event was already logged. PutLogEvents actions are now always accepted and +// never return DataAlreadyAcceptedException regardless of whether a given batch of +// log events has already been accepted. type DataAlreadyAcceptedException struct { Message *string @@ -68,6 +70,8 @@ func (e *InvalidParameterException) ErrorFault() smithy.ErrorFault { return smit // The sequence token is not valid. You can get the correct sequence token in the // expectedSequenceToken field in the InvalidSequenceTokenException message. +// PutLogEvents actions are now always accepted and never return +// InvalidSequenceTokenException regardless of receiving an invalid sequence token. type InvalidSequenceTokenException struct { Message *string diff --git a/service/cloudwatchlogs/types/types.go b/service/cloudwatchlogs/types/types.go index db99c14866b..ed371e1a118 100644 --- a/service/cloudwatchlogs/types/types.go +++ b/service/cloudwatchlogs/types/types.go @@ -209,7 +209,9 @@ type LogStream struct { LastEventTimestamp *int64 // The ingestion time, expressed as the number of milliseconds after Jan 1, 1970 - // 00:00:00 UTC. + // 00:00:00 UTC The lastIngestionTime value updates on an eventual consistency + // basis. It typically updates in less than an hour after ingestion, but in rare + // situations might take longer. LastIngestionTime *int64 // The name of the log stream. @@ -225,7 +227,10 @@ type LogStream struct { // The storedBytes parameter for log groups is not affected. StoredBytes *int64 - // The sequence token. + // The sequence token. The sequence token is now ignored in PutLogEvents actions. + // PutLogEvents actions are always accepted regardless of receiving an invalid + // sequence token. You don't need to obtain uploadSequenceToken to use a + // PutLogEvents action. UploadSequenceToken *string noSmithyDocumentSerde diff --git a/service/ssm/api_op_UpdateAssociation.go b/service/ssm/api_op_UpdateAssociation.go index 03f63ff2d70..daa8c90d53a 100644 --- a/service/ssm/api_op_UpdateAssociation.go +++ b/service/ssm/api_op_UpdateAssociation.go @@ -24,11 +24,11 @@ import ( // role must be configured with permission to call the DescribeAssociation API // operation. If you don't have permission to call DescribeAssociation, then you // receive the following error: An error occurred (AccessDeniedException) when -// calling the UpdateAssociation operation: User: isn't authorized to -// perform: ssm:DescribeAssociation on resource: When you update an -// association, the association immediately runs against the specified targets. You -// can add the ApplyOnlyAtCronInterval parameter to run the association during the -// next schedule run. +// calling the UpdateAssociation operation: User: isn't authorized to perform: +// ssm:DescribeAssociation on resource: When you update an association, the +// association immediately runs against the specified targets. You can add the +// ApplyOnlyAtCronInterval parameter to run the association during the next +// schedule run. func (c *Client) UpdateAssociation(ctx context.Context, params *UpdateAssociationInput, optFns ...func(*Options)) (*UpdateAssociationOutput, error) { if params == nil { params = &UpdateAssociationInput{} diff --git a/service/ssm/deserializers.go b/service/ssm/deserializers.go index f4d3ea4b221..ab76d5f9a98 100644 --- a/service/ssm/deserializers.go +++ b/service/ssm/deserializers.go @@ -26343,6 +26343,15 @@ func awsAwsjson11_deserializeDocumentDocumentRequires(v **types.DocumentRequires sv.Name = ptr.String(jtv) } + case "RequireType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected RequireType to be of type string, got %T instead", value) + } + sv.RequireType = ptr.String(jtv) + } + case "Version": if value != nil { jtv, ok := value.(string) @@ -26352,6 +26361,15 @@ func awsAwsjson11_deserializeDocumentDocumentRequires(v **types.DocumentRequires sv.Version = ptr.String(jtv) } + case "VersionName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected DocumentVersionName to be of type string, got %T instead", value) + } + sv.VersionName = ptr.String(jtv) + } + default: _, _ = key, value diff --git a/service/ssm/serializers.go b/service/ssm/serializers.go index aa6db0c0d76..3903bfa5fe5 100644 --- a/service/ssm/serializers.go +++ b/service/ssm/serializers.go @@ -8435,11 +8435,21 @@ func awsAwsjson11_serializeDocumentDocumentRequires(v *types.DocumentRequires, v ok.String(*v.Name) } + if v.RequireType != nil { + ok := object.Key("RequireType") + ok.String(*v.RequireType) + } + if v.Version != nil { ok := object.Key("Version") ok.String(*v.Version) } + if v.VersionName != nil { + ok := object.Key("VersionName") + ok.String(*v.VersionName) + } + return nil } diff --git a/service/ssm/types/enums.go b/service/ssm/types/enums.go index 03ee51b9057..041225615a9 100644 --- a/service/ssm/types/enums.go +++ b/service/ssm/types/enums.go @@ -757,6 +757,7 @@ const ( DocumentTypeProblemAnalysisTemplate DocumentType = "ProblemAnalysisTemplate" DocumentTypeCloudFormation DocumentType = "CloudFormation" DocumentTypeConformancePackTemplate DocumentType = "ConformancePackTemplate" + DocumentTypeQuickSetup DocumentType = "QuickSetup" ) // Values returns all known values for DocumentType. Note that this can be expanded @@ -778,6 +779,7 @@ func (DocumentType) Values() []DocumentType { "ProblemAnalysisTemplate", "CloudFormation", "ConformancePackTemplate", + "QuickSetup", } } diff --git a/service/ssm/types/types.go b/service/ssm/types/types.go index 4a57b2072de..40dd63fa8b0 100644 --- a/service/ssm/types/types.go +++ b/service/ssm/types/types.go @@ -2004,9 +2004,17 @@ type DocumentRequires struct { // This member is required. Name *string + // The document type of the required SSM document. + RequireType *string + // The document version required by the current document. Version *string + // An optional field specifying the version of the artifact associated with the + // document. For example, "Release 12, Update 6". This value is unique across all + // versions of a document, and can't be changed. + VersionName *string + noSmithyDocumentSerde }