applicationautoscaling

package
v0.24.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 22, 2020 License: Apache-2.0 Imports: 8 Imported by: 57

Documentation

Overview

Package applicationautoscaling provides the client and types for making API requests to Application Auto Scaling.

With Application Auto Scaling, you can configure automatic scaling for the following resources:

  • Amazon ECS services

  • Amazon EC2 Spot Fleet requests

  • Amazon EMR clusters

  • Amazon AppStream 2.0 fleets

  • Amazon DynamoDB tables and global secondary indexes throughput capacity

  • Amazon Aurora Replicas

  • Amazon SageMaker endpoint variants

  • Custom resources provided by your own applications or services

  • Amazon Comprehend document classification endpoints

  • AWS Lambda function provisioned concurrency

  • Amazon Keyspaces (for Apache Cassandra) tables

API Summary

The Application Auto Scaling service API includes three key sets of actions:

  • Register and manage scalable targets - Register AWS or custom resources as scalable targets (a resource that Application Auto Scaling can scale), set minimum and maximum capacity limits, and retrieve information on existing scalable targets.

  • Configure and manage automatic scaling - Define scaling policies to dynamically scale your resources in response to CloudWatch alarms, schedule one-time or recurring scaling actions, and retrieve your recent scaling activity history.

  • Suspend and resume scaling - Temporarily suspend and later resume automatic scaling by calling the RegisterScalableTarget (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_RegisterScalableTarget.html) API action for any Application Auto Scaling scalable target. You can suspend and resume (individually or in combination) scale-out activities that are triggered by a scaling policy, scale-in activities that are triggered by a scaling policy, and scheduled scaling.

To learn more about Application Auto Scaling, including information about granting IAM users required permissions for Application Auto Scaling actions, see the Application Auto Scaling User Guide (https://docs.aws.amazon.com/autoscaling/application/userguide/what-is-application-auto-scaling.html).

See https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06 for more information on this service.

See applicationautoscaling package documentation for more information. https://docs.aws.amazon.com/sdk-for-go/api/service/applicationautoscaling/

Using the Client

To use Application Auto Scaling with the SDK use the New function to create a new service client. With that client you can make API requests to the service. These clients are safe to use concurrently.

See the SDK's documentation for more information on how to use the SDK. https://docs.aws.amazon.com/sdk-for-go/api/

See aws.Config documentation for more information on configuring SDK clients. https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config

See the Application Auto Scaling client for more information on creating client for this service. https://docs.aws.amazon.com/sdk-for-go/api/service/applicationautoscaling/#New

Index

Examples

Constants

View Source
const (
	ServiceName = "Application Auto Scaling" // Service's name
	ServiceID   = "ApplicationAutoScaling"   // Service's identifier
	EndpointsID = "application-autoscaling"  // Service's Endpoint identifier
)
View Source
const (

	// ErrCodeConcurrentUpdateException for service response error code
	// "ConcurrentUpdateException".
	//
	// Concurrent updates caused an exception, for example, if you request an update
	// to an Application Auto Scaling resource that already has a pending update.
	ErrCodeConcurrentUpdateException = "ConcurrentUpdateException"

	// ErrCodeFailedResourceAccessException for service response error code
	// "FailedResourceAccessException".
	//
	// Failed access to resources caused an exception. This exception is thrown
	// when Application Auto Scaling is unable to retrieve the alarms associated
	// with a scaling policy due to a client error, for example, if the role ARN
	// specified for a scalable target does not have permission to call the CloudWatch
	// DescribeAlarms (https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_DescribeAlarms.html)
	// on your behalf.
	ErrCodeFailedResourceAccessException = "FailedResourceAccessException"

	// ErrCodeInternalServiceException for service response error code
	// "InternalServiceException".
	//
	// The service encountered an internal error.
	ErrCodeInternalServiceException = "InternalServiceException"

	// ErrCodeInvalidNextTokenException for service response error code
	// "InvalidNextTokenException".
	//
	// The next token supplied was invalid.
	ErrCodeInvalidNextTokenException = "InvalidNextTokenException"

	// ErrCodeLimitExceededException for service response error code
	// "LimitExceededException".
	//
	// A per-account resource limit is exceeded. For more information, see Application
	// Auto Scaling Limits (https://docs.aws.amazon.com/ApplicationAutoScaling/latest/userguide/application-auto-scaling-limits.html).
	ErrCodeLimitExceededException = "LimitExceededException"

	// ErrCodeObjectNotFoundException for service response error code
	// "ObjectNotFoundException".
	//
	// The specified object could not be found. For any operation that depends on
	// the existence of a scalable target, this exception is thrown if the scalable
	// target with the specified service namespace, resource ID, and scalable dimension
	// does not exist. For any operation that deletes or deregisters a resource,
	// this exception is thrown if the resource cannot be found.
	ErrCodeObjectNotFoundException = "ObjectNotFoundException"

	// ErrCodeValidationException for service response error code
	// "ValidationException".
	//
	// An exception was thrown for a validation issue. Review the available parameters
	// for the API request.
	ErrCodeValidationException = "ValidationException"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AdjustmentType

type AdjustmentType string
const (
	AdjustmentTypeChangeInCapacity        AdjustmentType = "ChangeInCapacity"
	AdjustmentTypePercentChangeInCapacity AdjustmentType = "PercentChangeInCapacity"
	AdjustmentTypeExactCapacity           AdjustmentType = "ExactCapacity"
)

Enum values for AdjustmentType

func (AdjustmentType) MarshalValue added in v0.3.0

func (enum AdjustmentType) MarshalValue() (string, error)

func (AdjustmentType) MarshalValueBuf added in v0.3.0

func (enum AdjustmentType) MarshalValueBuf(b []byte) ([]byte, error)

type Alarm

type Alarm struct {

	// The Amazon Resource Name (ARN) of the alarm.
	//
	// AlarmARN is a required field
	AlarmARN *string `type:"string" required:"true"`

	// The name of the alarm.
	//
	// AlarmName is a required field
	AlarmName *string `type:"string" required:"true"`
	// contains filtered or unexported fields
}

Represents a CloudWatch alarm associated with a scaling policy.

func (Alarm) String

func (s Alarm) String() string

String returns the string representation

type Client added in v0.9.0

type Client struct {
	*aws.Client
}

Client provides the API operation methods for making requests to Application Auto Scaling. See this package's package overview docs for details on the service.

The client's methods are safe to use concurrently. It is not safe to modify mutate any of the struct's properties though.

func New

func New(config aws.Config) *Client

New creates a new instance of the client from the provided Config.

Example:

// Create a client from just a config.
svc := applicationautoscaling.New(myConfig)

func (*Client) DeleteScalingPolicyRequest added in v0.9.0

func (c *Client) DeleteScalingPolicyRequest(input *DeleteScalingPolicyInput) DeleteScalingPolicyRequest

DeleteScalingPolicyRequest returns a request value for making API operation for Application Auto Scaling.

Deletes the specified scaling policy for an Application Auto Scaling scalable target.

Deleting a step scaling policy deletes the underlying alarm action, but does not delete the CloudWatch alarm associated with the scaling policy, even if it no longer has an associated action.

For more information, see Delete a Step Scaling Policy (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-step-scaling-policies.html#delete-step-scaling-policy) and Delete a Target Tracking Scaling Policy (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-target-tracking.html#delete-target-tracking-policy) in the Application Auto Scaling User Guide.

// Example sending a request using DeleteScalingPolicyRequest.
req := client.DeleteScalingPolicyRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DeleteScalingPolicy

Example (Shared00)

To delete a scaling policy

This example deletes a scaling policy for the Amazon ECS service called web-app, which is running in the default cluster.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.DeleteScalingPolicyInput{
		PolicyName:        aws.String("web-app-cpu-lt-25"),
		ResourceId:        aws.String("service/default/web-app"),
		ScalableDimension: applicationautoscaling.ScalableDimensionEcsServiceDesiredCount,
		ServiceNamespace:  applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.DeleteScalingPolicyRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeObjectNotFoundException:
				fmt.Println(applicationautoscaling.ErrCodeObjectNotFoundException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) DeleteScheduledActionRequest added in v0.9.0

func (c *Client) DeleteScheduledActionRequest(input *DeleteScheduledActionInput) DeleteScheduledActionRequest

DeleteScheduledActionRequest returns a request value for making API operation for Application Auto Scaling.

Deletes the specified scheduled action for an Application Auto Scaling scalable target.

For more information, see Delete a Scheduled Action (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scheduled-scaling.html#delete-scheduled-action) in the Application Auto Scaling User Guide.

// Example sending a request using DeleteScheduledActionRequest.
req := client.DeleteScheduledActionRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DeleteScheduledAction

func (*Client) DeregisterScalableTargetRequest added in v0.9.0

func (c *Client) DeregisterScalableTargetRequest(input *DeregisterScalableTargetInput) DeregisterScalableTargetRequest

DeregisterScalableTargetRequest returns a request value for making API operation for Application Auto Scaling.

Deregisters an Application Auto Scaling scalable target when you have finished using it. To see which resources have been registered, use DescribeScalableTargets (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_DescribeScalableTargets.html).

Deregistering a scalable target deletes the scaling policies and the scheduled actions that are associated with it.

// Example sending a request using DeregisterScalableTargetRequest.
req := client.DeregisterScalableTargetRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DeregisterScalableTarget

Example (Shared00)

To deregister a scalable target

This example deregisters a scalable target for an Amazon ECS service called web-app that is running in the default cluster.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.DeregisterScalableTargetInput{
		ResourceId:        aws.String("service/default/web-app"),
		ScalableDimension: applicationautoscaling.ScalableDimensionEcsServiceDesiredCount,
		ServiceNamespace:  applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.DeregisterScalableTargetRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeObjectNotFoundException:
				fmt.Println(applicationautoscaling.ErrCodeObjectNotFoundException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) DescribeScalableTargetsRequest added in v0.9.0

func (c *Client) DescribeScalableTargetsRequest(input *DescribeScalableTargetsInput) DescribeScalableTargetsRequest

DescribeScalableTargetsRequest returns a request value for making API operation for Application Auto Scaling.

Gets information about the scalable targets in the specified namespace.

You can filter the results using ResourceIds and ScalableDimension.

// Example sending a request using DescribeScalableTargetsRequest.
req := client.DescribeScalableTargetsRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalableTargets

Example (Shared00)

To describe scalable targets

This example describes the scalable targets for the ECS service namespace.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.DescribeScalableTargetsInput{
		ServiceNamespace: applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.DescribeScalableTargetsRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeInvalidNextTokenException:
				fmt.Println(applicationautoscaling.ErrCodeInvalidNextTokenException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) DescribeScalingActivitiesRequest added in v0.9.0

func (c *Client) DescribeScalingActivitiesRequest(input *DescribeScalingActivitiesInput) DescribeScalingActivitiesRequest

DescribeScalingActivitiesRequest returns a request value for making API operation for Application Auto Scaling.

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.

// Example sending a request using DescribeScalingActivitiesRequest.
req := client.DescribeScalingActivitiesRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalingActivities

Example (Shared00)

To describe scaling activities for a scalable target

This example describes the scaling activities for an Amazon ECS service called web-app that is running in the default cluster.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.DescribeScalingActivitiesInput{
		ResourceId:        aws.String("service/default/web-app"),
		ScalableDimension: applicationautoscaling.ScalableDimensionEcsServiceDesiredCount,
		ServiceNamespace:  applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.DescribeScalingActivitiesRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeInvalidNextTokenException:
				fmt.Println(applicationautoscaling.ErrCodeInvalidNextTokenException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) DescribeScalingPoliciesRequest added in v0.9.0

func (c *Client) DescribeScalingPoliciesRequest(input *DescribeScalingPoliciesInput) DescribeScalingPoliciesRequest

DescribeScalingPoliciesRequest returns a request value for making API operation for Application Auto Scaling.

Describes the Application Auto Scaling scaling policies for the specified service namespace.

You can filter the results using ResourceId, ScalableDimension, and PolicyNames.

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) in the Application Auto Scaling User Guide.

// Example sending a request using DescribeScalingPoliciesRequest.
req := client.DescribeScalingPoliciesRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScalingPolicies

Example (Shared00)

To describe scaling policies

This example describes the scaling policies for the ECS service namespace.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.DescribeScalingPoliciesInput{
		ServiceNamespace: applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.DescribeScalingPoliciesRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeFailedResourceAccessException:
				fmt.Println(applicationautoscaling.ErrCodeFailedResourceAccessException, aerr.Error())
			case applicationautoscaling.ErrCodeInvalidNextTokenException:
				fmt.Println(applicationautoscaling.ErrCodeInvalidNextTokenException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) DescribeScheduledActionsRequest added in v0.9.0

func (c *Client) DescribeScheduledActionsRequest(input *DescribeScheduledActionsInput) DescribeScheduledActionsRequest

DescribeScheduledActionsRequest returns a request value for making API operation for Application Auto Scaling.

Describes the Application Auto Scaling scheduled actions for the specified service namespace.

You can filter the results using the ResourceId, ScalableDimension, and ScheduledActionNames parameters.

For more information, see Scheduled Scaling (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scheduled-scaling.html) in the Application Auto Scaling User Guide.

// Example sending a request using DescribeScheduledActionsRequest.
req := client.DescribeScheduledActionsRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/DescribeScheduledActions

func (*Client) PutScalingPolicyRequest added in v0.9.0

func (c *Client) PutScalingPolicyRequest(input *PutScalingPolicyInput) PutScalingPolicyRequest

PutScalingPolicyRequest returns a request value for making API operation for Application Auto Scaling.

Creates or updates a scaling policy for an Application Auto Scaling scalable target.

Each scalable target is identified by a service namespace, resource ID, and scalable dimension. A scaling policy applies to the scalable target identified by those three attributes. You cannot create a scaling policy until you have registered the resource as a scalable target.

Multiple scaling policies can be in force at the same time for the same scalable target. You can have one or more target tracking scaling policies, one or more step scaling policies, or both. However, there is a chance that multiple policies could conflict, instructing the scalable target to scale out or in at the same time. Application Auto Scaling gives precedence to the policy that provides the largest capacity for both scale out and scale in. For example, if one policy increases capacity by 3, another policy increases capacity by 200 percent, and the current capacity is 10, Application Auto Scaling uses the policy with the highest calculated capacity (200% of 10 = 20) and scales out to 30.

We recommend caution, however, when using target tracking scaling policies with step scaling policies because conflicts between these policies can cause undesirable behavior. For example, if the step scaling policy initiates a scale-in activity before the target tracking policy is ready to scale in, the scale-in activity will not be blocked. After the scale-in activity completes, the target tracking policy could instruct the scalable target to scale out again.

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) in the Application Auto Scaling User Guide.

If a scalable target is deregistered, the scalable target is no longer available to execute scaling policies. Any scaling policies that were specified for the scalable target are deleted.

// Example sending a request using PutScalingPolicyRequest.
req := client.PutScalingPolicyRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/PutScalingPolicy

Example (Shared00)

To apply a target tracking scaling policy with a predefined metric specification

The following example applies a target tracking scaling policy with a predefined metric specification to an Amazon ECS service called web-app in the default cluster. The policy keeps the average CPU utilization of the service at 75 percent, with scale-out and scale-in cooldown periods of 60 seconds.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.PutScalingPolicyInput{
		PolicyName:        aws.String("cpu75-target-tracking-scaling-policy"),
		PolicyType:        applicationautoscaling.PolicyTypeTargetTrackingScaling,
		ResourceId:        aws.String("service/default/web-app"),
		ScalableDimension: applicationautoscaling.ScalableDimensionEcsServiceDesiredCount,
		ServiceNamespace:  applicationautoscaling.ServiceNamespaceEcs,
		TargetTrackingScalingPolicyConfiguration: &applicationautoscaling.TargetTrackingScalingPolicyConfiguration{
			PredefinedMetricSpecification: &applicationautoscaling.PredefinedMetricSpecification{
				PredefinedMetricType: applicationautoscaling.MetricTypeEcsserviceAverageCpuutilization,
			},
			ScaleInCooldown:  aws.Int64(60),
			ScaleOutCooldown: aws.Int64(60),
			TargetValue:      aws.Float64(75.000000),
		},
	}

	req := svc.PutScalingPolicyRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeLimitExceededException:
				fmt.Println(applicationautoscaling.ErrCodeLimitExceededException, aerr.Error())
			case applicationautoscaling.ErrCodeObjectNotFoundException:
				fmt.Println(applicationautoscaling.ErrCodeObjectNotFoundException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeFailedResourceAccessException:
				fmt.Println(applicationautoscaling.ErrCodeFailedResourceAccessException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

func (*Client) PutScheduledActionRequest added in v0.9.0

func (c *Client) PutScheduledActionRequest(input *PutScheduledActionInput) PutScheduledActionRequest

PutScheduledActionRequest returns a request value for making API operation for Application Auto Scaling.

Creates or updates a scheduled action for an Application Auto Scaling scalable target.

Each scalable target is identified by a service namespace, resource ID, and scalable dimension. A scheduled action applies to the scalable target identified by those three attributes. You cannot create a scheduled action until you have registered the resource as a scalable target.

When start and end times are specified with a recurring schedule using a cron expression or rates, they form the boundaries of when the recurring action starts and stops.

To update a scheduled action, specify the parameters that you want to change. If you don't specify start and end times, the old values are deleted.

For more information, see Scheduled Scaling (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scheduled-scaling.html) in the Application Auto Scaling User Guide.

If a scalable target is deregistered, the scalable target is no longer available to run scheduled actions. Any scheduled actions that were specified for the scalable target are deleted.

// Example sending a request using PutScheduledActionRequest.
req := client.PutScheduledActionRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/PutScheduledAction

func (*Client) RegisterScalableTargetRequest added in v0.9.0

func (c *Client) RegisterScalableTargetRequest(input *RegisterScalableTargetInput) RegisterScalableTargetRequest

RegisterScalableTargetRequest returns a request value for making API operation for Application Auto Scaling.

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. 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 (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 (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_DescribeScalableTargets.html). If you no longer need a scalable target, you can deregister it by using DeregisterScalableTarget (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_DeregisterScalableTarget.html).

To update a scalable target, specify the parameters that you want to change. Include the parameters that identify the scalable target: resource ID, scalable dimension, and namespace. Any parameters that you don't specify are not changed by this update request.

// Example sending a request using RegisterScalableTargetRequest.
req := client.RegisterScalableTargetRequest(params)
resp, err := req.Send(context.TODO())
if err == nil {
    fmt.Println(resp)
}

Please also see https://docs.aws.amazon.com/goto/WebAPI/application-autoscaling-2016-02-06/RegisterScalableTarget

Example (Shared00)

To register an ECS service as a scalable target

This example registers a scalable target from an Amazon ECS service called web-app that is running on the default cluster, with a minimum desired count of 1 task and a maximum desired count of 10 tasks.

package main

import (
	"context"
	"fmt"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/aws/awserr"
	"github.com/aws/aws-sdk-go-v2/aws/external"
	"github.com/aws/aws-sdk-go-v2/service/applicationautoscaling"
)

func main() {
	cfg, err := external.LoadDefaultAWSConfig()
	if err != nil {
		panic("failed to load config, " + err.Error())
	}

	svc := applicationautoscaling.New(cfg)
	input := &applicationautoscaling.RegisterScalableTargetInput{
		MaxCapacity:       aws.Int64(10),
		MinCapacity:       aws.Int64(1),
		ResourceId:        aws.String("service/default/web-app"),
		ScalableDimension: applicationautoscaling.ScalableDimensionEcsServiceDesiredCount,
		ServiceNamespace:  applicationautoscaling.ServiceNamespaceEcs,
	}

	req := svc.RegisterScalableTargetRequest(input)
	result, err := req.Send(context.Background())
	if err != nil {
		if aerr, ok := err.(awserr.Error); ok {
			switch aerr.Code() {
			case applicationautoscaling.ErrCodeValidationException:
				fmt.Println(applicationautoscaling.ErrCodeValidationException, aerr.Error())
			case applicationautoscaling.ErrCodeLimitExceededException:
				fmt.Println(applicationautoscaling.ErrCodeLimitExceededException, aerr.Error())
			case applicationautoscaling.ErrCodeConcurrentUpdateException:
				fmt.Println(applicationautoscaling.ErrCodeConcurrentUpdateException, aerr.Error())
			case applicationautoscaling.ErrCodeInternalServiceException:
				fmt.Println(applicationautoscaling.ErrCodeInternalServiceException, aerr.Error())
			default:
				fmt.Println(aerr.Error())
			}
		} else {
			// Print the error, cast err to awserr.Error to get the Code and
			// Message from an error.
			fmt.Println(err.Error())
		}
		return
	}

	fmt.Println(result)
}
Output:

type CustomizedMetricSpecification

type CustomizedMetricSpecification struct {

	// The dimensions of the metric.
	//
	// Conditional: If you published your metric with dimensions, you must specify
	// the same dimensions in your scaling policy.
	Dimensions []MetricDimension `type:"list"`

	// The name of the metric.
	//
	// MetricName is a required field
	MetricName *string `type:"string" required:"true"`

	// The namespace of the metric.
	//
	// Namespace is a required field
	Namespace *string `type:"string" required:"true"`

	// The statistic of the metric.
	//
	// Statistic is a required field
	Statistic MetricStatistic `type:"string" required:"true" enum:"true"`

	// The unit of the metric.
	Unit *string `type:"string"`
	// contains filtered or unexported fields
}

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 AWS 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:

  • 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 (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/publishingMetrics.html) in the Amazon CloudWatch User Guide.

  • Choose a metric that changes proportionally with capacity. The value of the metric should increase or decrease in inverse proportion to the number of capacity units. That is, the 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).

func (CustomizedMetricSpecification) String

String returns the string representation

func (*CustomizedMetricSpecification) Validate

func (s *CustomizedMetricSpecification) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DeleteScalingPolicyInput

type DeleteScalingPolicyInput struct {

	// The name of the scaling policy.
	//
	// PolicyName is a required field
	PolicyName *string `min:"1" type:"string" required:"true"`

	// The identifier of the resource associated with the scalable target. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DeleteScalingPolicyInput) String

func (s DeleteScalingPolicyInput) String() string

String returns the string representation

func (*DeleteScalingPolicyInput) Validate

func (s *DeleteScalingPolicyInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DeleteScalingPolicyOutput

type DeleteScalingPolicyOutput struct {
	// contains filtered or unexported fields
}

func (DeleteScalingPolicyOutput) String

func (s DeleteScalingPolicyOutput) String() string

String returns the string representation

type DeleteScalingPolicyRequest

type DeleteScalingPolicyRequest struct {
	*aws.Request
	Input *DeleteScalingPolicyInput
	Copy  func(*DeleteScalingPolicyInput) DeleteScalingPolicyRequest
}

DeleteScalingPolicyRequest is the request type for the DeleteScalingPolicy API operation.

func (DeleteScalingPolicyRequest) Send

Send marshals and sends the DeleteScalingPolicy API request.

type DeleteScalingPolicyResponse added in v0.9.0

type DeleteScalingPolicyResponse struct {
	*DeleteScalingPolicyOutput
	// contains filtered or unexported fields
}

DeleteScalingPolicyResponse is the response type for the DeleteScalingPolicy API operation.

func (*DeleteScalingPolicyResponse) SDKResponseMetdata added in v0.9.0

func (r *DeleteScalingPolicyResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DeleteScalingPolicy request.

type DeleteScheduledActionInput added in v0.2.0

type DeleteScheduledActionInput struct {

	// The identifier of the resource associated with the scheduled action. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The name of the scheduled action.
	//
	// ScheduledActionName is a required field
	ScheduledActionName *string `min:"1" type:"string" required:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DeleteScheduledActionInput) String added in v0.2.0

String returns the string representation

func (*DeleteScheduledActionInput) Validate added in v0.2.0

func (s *DeleteScheduledActionInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DeleteScheduledActionOutput added in v0.2.0

type DeleteScheduledActionOutput struct {
	// contains filtered or unexported fields
}

func (DeleteScheduledActionOutput) String added in v0.2.0

String returns the string representation

type DeleteScheduledActionRequest added in v0.2.0

type DeleteScheduledActionRequest struct {
	*aws.Request
	Input *DeleteScheduledActionInput
	Copy  func(*DeleteScheduledActionInput) DeleteScheduledActionRequest
}

DeleteScheduledActionRequest is the request type for the DeleteScheduledAction API operation.

func (DeleteScheduledActionRequest) Send added in v0.2.0

Send marshals and sends the DeleteScheduledAction API request.

type DeleteScheduledActionResponse added in v0.9.0

type DeleteScheduledActionResponse struct {
	*DeleteScheduledActionOutput
	// contains filtered or unexported fields
}

DeleteScheduledActionResponse is the response type for the DeleteScheduledAction API operation.

func (*DeleteScheduledActionResponse) SDKResponseMetdata added in v0.9.0

func (r *DeleteScheduledActionResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DeleteScheduledAction request.

type DeregisterScalableTargetInput

type DeregisterScalableTargetInput struct {

	// The identifier of the resource associated with the scalable target. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension associated with the scalable target. This string consists
	// of the service namespace, resource type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DeregisterScalableTargetInput) String

String returns the string representation

func (*DeregisterScalableTargetInput) Validate

func (s *DeregisterScalableTargetInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DeregisterScalableTargetOutput

type DeregisterScalableTargetOutput struct {
	// contains filtered or unexported fields
}

func (DeregisterScalableTargetOutput) String

String returns the string representation

type DeregisterScalableTargetRequest

type DeregisterScalableTargetRequest struct {
	*aws.Request
	Input *DeregisterScalableTargetInput
	Copy  func(*DeregisterScalableTargetInput) DeregisterScalableTargetRequest
}

DeregisterScalableTargetRequest is the request type for the DeregisterScalableTarget API operation.

func (DeregisterScalableTargetRequest) Send

Send marshals and sends the DeregisterScalableTarget API request.

type DeregisterScalableTargetResponse added in v0.9.0

type DeregisterScalableTargetResponse struct {
	*DeregisterScalableTargetOutput
	// contains filtered or unexported fields
}

DeregisterScalableTargetResponse is the response type for the DeregisterScalableTarget API operation.

func (*DeregisterScalableTargetResponse) SDKResponseMetdata added in v0.9.0

func (r *DeregisterScalableTargetResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DeregisterScalableTarget request.

type DescribeScalableTargetsInput

type DescribeScalableTargetsInput struct {

	// 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 of results,
	// include the NextToken value in a subsequent call. If this parameter is not
	// used, the operation returns up to 50 results and a NextToken value, if applicable.
	MaxResults *int64 `type:"integer"`

	// The token for the next set of results.
	NextToken *string `type:"string"`

	// The identifier of the resource associated with the scalable target. This
	// string consists of the resource type and unique identifier. If you specify
	// a scalable dimension, you must also specify a resource ID.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	ResourceIds []string `type:"list"`

	// The scalable dimension associated with the scalable target. This string consists
	// of the service namespace, resource type, and scaling property. If you specify
	// a scalable dimension, you must also specify a resource ID.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	ScalableDimension ScalableDimension `type:"string" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DescribeScalableTargetsInput) String

String returns the string representation

func (*DescribeScalableTargetsInput) Validate

func (s *DescribeScalableTargetsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DescribeScalableTargetsOutput

type DescribeScalableTargetsOutput struct {

	// The token required to get the next set of results. This value is null if
	// there are no more results to return.
	NextToken *string `type:"string"`

	// The scalable targets that match the request parameters.
	ScalableTargets []ScalableTarget `type:"list"`
	// contains filtered or unexported fields
}

func (DescribeScalableTargetsOutput) String

String returns the string representation

type DescribeScalableTargetsPaginator added in v0.9.0

type DescribeScalableTargetsPaginator struct {
	aws.Pager
}

DescribeScalableTargetsPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.

func NewDescribeScalableTargetsPaginator added in v0.9.0

func NewDescribeScalableTargetsPaginator(req DescribeScalableTargetsRequest) DescribeScalableTargetsPaginator

NewDescribeScalableTargetsRequestPaginator returns a paginator for DescribeScalableTargets. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.

Note: This operation can generate multiple requests to a service.

// Example iterating over pages.
req := client.DescribeScalableTargetsRequest(input)
p := applicationautoscaling.NewDescribeScalableTargetsRequestPaginator(req)

for p.Next(context.TODO()) {
    page := p.CurrentPage()
}

if err := p.Err(); err != nil {
    return err
}

func (*DescribeScalableTargetsPaginator) CurrentPage added in v0.9.0

type DescribeScalableTargetsRequest

type DescribeScalableTargetsRequest struct {
	*aws.Request
	Input *DescribeScalableTargetsInput
	Copy  func(*DescribeScalableTargetsInput) DescribeScalableTargetsRequest
}

DescribeScalableTargetsRequest is the request type for the DescribeScalableTargets API operation.

func (DescribeScalableTargetsRequest) Send

Send marshals and sends the DescribeScalableTargets API request.

type DescribeScalableTargetsResponse added in v0.9.0

type DescribeScalableTargetsResponse struct {
	*DescribeScalableTargetsOutput
	// contains filtered or unexported fields
}

DescribeScalableTargetsResponse is the response type for the DescribeScalableTargets API operation.

func (*DescribeScalableTargetsResponse) SDKResponseMetdata added in v0.9.0

func (r *DescribeScalableTargetsResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DescribeScalableTargets request.

type DescribeScalingActivitiesInput

type DescribeScalingActivitiesInput struct {

	// 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 of results,
	// include the NextToken value in a subsequent call. If this parameter is not
	// used, the operation returns up to 50 results and a NextToken value, if applicable.
	MaxResults *int64 `type:"integer"`

	// The token for the next set of results.
	NextToken *string `type:"string"`

	// The identifier of the resource associated with the scaling activity. This
	// string consists of the resource type and unique identifier. If you specify
	// a scalable dimension, you must also specify a resource ID.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	ResourceId *string `min:"1" type:"string"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property. If you specify a scalable dimension, you must
	// also specify a resource ID.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	ScalableDimension ScalableDimension `type:"string" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DescribeScalingActivitiesInput) String

String returns the string representation

func (*DescribeScalingActivitiesInput) Validate

func (s *DescribeScalingActivitiesInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DescribeScalingActivitiesOutput

type DescribeScalingActivitiesOutput struct {

	// The token required to get the next set of results. This value is null if
	// there are no more results to return.
	NextToken *string `type:"string"`

	// A list of scaling activity objects.
	ScalingActivities []ScalingActivity `type:"list"`
	// contains filtered or unexported fields
}

func (DescribeScalingActivitiesOutput) String

String returns the string representation

type DescribeScalingActivitiesPaginator added in v0.9.0

type DescribeScalingActivitiesPaginator struct {
	aws.Pager
}

DescribeScalingActivitiesPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.

func NewDescribeScalingActivitiesPaginator added in v0.9.0

func NewDescribeScalingActivitiesPaginator(req DescribeScalingActivitiesRequest) DescribeScalingActivitiesPaginator

NewDescribeScalingActivitiesRequestPaginator returns a paginator for DescribeScalingActivities. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.

Note: This operation can generate multiple requests to a service.

// Example iterating over pages.
req := client.DescribeScalingActivitiesRequest(input)
p := applicationautoscaling.NewDescribeScalingActivitiesRequestPaginator(req)

for p.Next(context.TODO()) {
    page := p.CurrentPage()
}

if err := p.Err(); err != nil {
    return err
}

func (*DescribeScalingActivitiesPaginator) CurrentPage added in v0.9.0

type DescribeScalingActivitiesRequest

type DescribeScalingActivitiesRequest struct {
	*aws.Request
	Input *DescribeScalingActivitiesInput
	Copy  func(*DescribeScalingActivitiesInput) DescribeScalingActivitiesRequest
}

DescribeScalingActivitiesRequest is the request type for the DescribeScalingActivities API operation.

func (DescribeScalingActivitiesRequest) Send

Send marshals and sends the DescribeScalingActivities API request.

type DescribeScalingActivitiesResponse added in v0.9.0

type DescribeScalingActivitiesResponse struct {
	*DescribeScalingActivitiesOutput
	// contains filtered or unexported fields
}

DescribeScalingActivitiesResponse is the response type for the DescribeScalingActivities API operation.

func (*DescribeScalingActivitiesResponse) SDKResponseMetdata added in v0.9.0

func (r *DescribeScalingActivitiesResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DescribeScalingActivities request.

type DescribeScalingPoliciesInput

type DescribeScalingPoliciesInput struct {

	// 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 of results,
	// include the NextToken value in a subsequent call. If this parameter is not
	// used, the operation returns up to 50 results and a NextToken value, if applicable.
	MaxResults *int64 `type:"integer"`

	// The token for the next set of results.
	NextToken *string `type:"string"`

	// The names of the scaling policies to describe.
	PolicyNames []string `type:"list"`

	// The identifier of the resource associated with the scaling policy. This string
	// consists of the resource type and unique identifier. If you specify a scalable
	// dimension, you must also specify a resource ID.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	ResourceId *string `min:"1" type:"string"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property. If you specify a scalable dimension, you must
	// also specify a resource ID.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	ScalableDimension ScalableDimension `type:"string" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DescribeScalingPoliciesInput) String

String returns the string representation

func (*DescribeScalingPoliciesInput) Validate

func (s *DescribeScalingPoliciesInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DescribeScalingPoliciesOutput

type DescribeScalingPoliciesOutput struct {

	// The token required to get the next set of results. This value is null if
	// there are no more results to return.
	NextToken *string `type:"string"`

	// Information about the scaling policies.
	ScalingPolicies []ScalingPolicy `type:"list"`
	// contains filtered or unexported fields
}

func (DescribeScalingPoliciesOutput) String

String returns the string representation

type DescribeScalingPoliciesPaginator added in v0.9.0

type DescribeScalingPoliciesPaginator struct {
	aws.Pager
}

DescribeScalingPoliciesPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.

func NewDescribeScalingPoliciesPaginator added in v0.9.0

func NewDescribeScalingPoliciesPaginator(req DescribeScalingPoliciesRequest) DescribeScalingPoliciesPaginator

NewDescribeScalingPoliciesRequestPaginator returns a paginator for DescribeScalingPolicies. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.

Note: This operation can generate multiple requests to a service.

// Example iterating over pages.
req := client.DescribeScalingPoliciesRequest(input)
p := applicationautoscaling.NewDescribeScalingPoliciesRequestPaginator(req)

for p.Next(context.TODO()) {
    page := p.CurrentPage()
}

if err := p.Err(); err != nil {
    return err
}

func (*DescribeScalingPoliciesPaginator) CurrentPage added in v0.9.0

type DescribeScalingPoliciesRequest

type DescribeScalingPoliciesRequest struct {
	*aws.Request
	Input *DescribeScalingPoliciesInput
	Copy  func(*DescribeScalingPoliciesInput) DescribeScalingPoliciesRequest
}

DescribeScalingPoliciesRequest is the request type for the DescribeScalingPolicies API operation.

func (DescribeScalingPoliciesRequest) Send

Send marshals and sends the DescribeScalingPolicies API request.

type DescribeScalingPoliciesResponse added in v0.9.0

type DescribeScalingPoliciesResponse struct {
	*DescribeScalingPoliciesOutput
	// contains filtered or unexported fields
}

DescribeScalingPoliciesResponse is the response type for the DescribeScalingPolicies API operation.

func (*DescribeScalingPoliciesResponse) SDKResponseMetdata added in v0.9.0

func (r *DescribeScalingPoliciesResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DescribeScalingPolicies request.

type DescribeScheduledActionsInput added in v0.2.0

type DescribeScheduledActionsInput struct {

	// The maximum number of scheduled action results. 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 of results,
	// include the NextToken value in a subsequent call. If this parameter is not
	// used, the operation returns up to 50 results and a NextToken value, if applicable.
	MaxResults *int64 `type:"integer"`

	// The token for the next set of results.
	NextToken *string `type:"string"`

	// The identifier of the resource associated with the scheduled action. This
	// string consists of the resource type and unique identifier. If you specify
	// a scalable dimension, you must also specify a resource ID.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	ResourceId *string `min:"1" type:"string"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property. If you specify a scalable dimension, you must
	// also specify a resource ID.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	ScalableDimension ScalableDimension `type:"string" enum:"true"`

	// The names of the scheduled actions to describe.
	ScheduledActionNames []string `type:"list"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`
	// contains filtered or unexported fields
}

func (DescribeScheduledActionsInput) String added in v0.2.0

String returns the string representation

func (*DescribeScheduledActionsInput) Validate added in v0.2.0

func (s *DescribeScheduledActionsInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type DescribeScheduledActionsOutput added in v0.2.0

type DescribeScheduledActionsOutput struct {

	// The token required to get the next set of results. This value is null if
	// there are no more results to return.
	NextToken *string `type:"string"`

	// Information about the scheduled actions.
	ScheduledActions []ScheduledAction `type:"list"`
	// contains filtered or unexported fields
}

func (DescribeScheduledActionsOutput) String added in v0.2.0

String returns the string representation

type DescribeScheduledActionsPaginator added in v0.12.0

type DescribeScheduledActionsPaginator struct {
	aws.Pager
}

DescribeScheduledActionsPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.

func NewDescribeScheduledActionsPaginator added in v0.12.0

func NewDescribeScheduledActionsPaginator(req DescribeScheduledActionsRequest) DescribeScheduledActionsPaginator

NewDescribeScheduledActionsRequestPaginator returns a paginator for DescribeScheduledActions. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.

Note: This operation can generate multiple requests to a service.

// Example iterating over pages.
req := client.DescribeScheduledActionsRequest(input)
p := applicationautoscaling.NewDescribeScheduledActionsRequestPaginator(req)

for p.Next(context.TODO()) {
    page := p.CurrentPage()
}

if err := p.Err(); err != nil {
    return err
}

func (*DescribeScheduledActionsPaginator) CurrentPage added in v0.12.0

type DescribeScheduledActionsRequest added in v0.2.0

type DescribeScheduledActionsRequest struct {
	*aws.Request
	Input *DescribeScheduledActionsInput
	Copy  func(*DescribeScheduledActionsInput) DescribeScheduledActionsRequest
}

DescribeScheduledActionsRequest is the request type for the DescribeScheduledActions API operation.

func (DescribeScheduledActionsRequest) Send added in v0.2.0

Send marshals and sends the DescribeScheduledActions API request.

type DescribeScheduledActionsResponse added in v0.9.0

type DescribeScheduledActionsResponse struct {
	*DescribeScheduledActionsOutput
	// contains filtered or unexported fields
}

DescribeScheduledActionsResponse is the response type for the DescribeScheduledActions API operation.

func (*DescribeScheduledActionsResponse) SDKResponseMetdata added in v0.9.0

func (r *DescribeScheduledActionsResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the DescribeScheduledActions request.

type MetricAggregationType

type MetricAggregationType string
const (
	MetricAggregationTypeAverage MetricAggregationType = "Average"
	MetricAggregationTypeMinimum MetricAggregationType = "Minimum"
	MetricAggregationTypeMaximum MetricAggregationType = "Maximum"
)

Enum values for MetricAggregationType

func (MetricAggregationType) MarshalValue added in v0.3.0

func (enum MetricAggregationType) MarshalValue() (string, error)

func (MetricAggregationType) MarshalValueBuf added in v0.3.0

func (enum MetricAggregationType) MarshalValueBuf(b []byte) ([]byte, error)

type MetricDimension

type MetricDimension struct {

	// The name of the dimension.
	//
	// Name is a required field
	Name *string `type:"string" required:"true"`

	// The value of the dimension.
	//
	// Value is a required field
	Value *string `type:"string" required:"true"`
	// contains filtered or unexported fields
}

Describes the dimension names and values associated with a metric.

func (MetricDimension) String

func (s MetricDimension) String() string

String returns the string representation

func (*MetricDimension) Validate

func (s *MetricDimension) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type MetricStatistic

type MetricStatistic string
const (
	MetricStatisticAverage     MetricStatistic = "Average"
	MetricStatisticMinimum     MetricStatistic = "Minimum"
	MetricStatisticMaximum     MetricStatistic = "Maximum"
	MetricStatisticSampleCount MetricStatistic = "SampleCount"
	MetricStatisticSum         MetricStatistic = "Sum"
)

Enum values for MetricStatistic

func (MetricStatistic) MarshalValue added in v0.3.0

func (enum MetricStatistic) MarshalValue() (string, error)

func (MetricStatistic) MarshalValueBuf added in v0.3.0

func (enum MetricStatistic) MarshalValueBuf(b []byte) ([]byte, error)

type MetricType

type MetricType string
const (
	MetricTypeDynamoDbreadCapacityUtilization          MetricType = "DynamoDBReadCapacityUtilization"
	MetricTypeDynamoDbwriteCapacityUtilization         MetricType = "DynamoDBWriteCapacityUtilization"
	MetricTypeAlbrequestCountPerTarget                 MetricType = "ALBRequestCountPerTarget"
	MetricTypeRdsreaderAverageCpuutilization           MetricType = "RDSReaderAverageCPUUtilization"
	MetricTypeRdsreaderAverageDatabaseConnections      MetricType = "RDSReaderAverageDatabaseConnections"
	MetricTypeEc2spotFleetRequestAverageCpuutilization MetricType = "EC2SpotFleetRequestAverageCPUUtilization"
	MetricTypeEc2spotFleetRequestAverageNetworkIn      MetricType = "EC2SpotFleetRequestAverageNetworkIn"
	MetricTypeEc2spotFleetRequestAverageNetworkOut     MetricType = "EC2SpotFleetRequestAverageNetworkOut"
	MetricTypeSageMakerVariantInvocationsPerInstance   MetricType = "SageMakerVariantInvocationsPerInstance"
	MetricTypeEcsserviceAverageCpuutilization          MetricType = "ECSServiceAverageCPUUtilization"
	MetricTypeEcsserviceAverageMemoryUtilization       MetricType = "ECSServiceAverageMemoryUtilization"
	MetricTypeAppStreamAverageCapacityUtilization      MetricType = "AppStreamAverageCapacityUtilization"
	MetricTypeComprehendInferenceUtilization           MetricType = "ComprehendInferenceUtilization"
	MetricTypeLambdaProvisionedConcurrencyUtilization  MetricType = "LambdaProvisionedConcurrencyUtilization"
	MetricTypeCassandraReadCapacityUtilization         MetricType = "CassandraReadCapacityUtilization"
	MetricTypeCassandraWriteCapacityUtilization        MetricType = "CassandraWriteCapacityUtilization"
)

Enum values for MetricType

func (MetricType) MarshalValue added in v0.3.0

func (enum MetricType) MarshalValue() (string, error)

func (MetricType) MarshalValueBuf added in v0.3.0

func (enum MetricType) MarshalValueBuf(b []byte) ([]byte, error)

type PolicyType

type PolicyType string
const (
	PolicyTypeStepScaling           PolicyType = "StepScaling"
	PolicyTypeTargetTrackingScaling PolicyType = "TargetTrackingScaling"
)

Enum values for PolicyType

func (PolicyType) MarshalValue added in v0.3.0

func (enum PolicyType) MarshalValue() (string, error)

func (PolicyType) MarshalValueBuf added in v0.3.0

func (enum PolicyType) MarshalValueBuf(b []byte) ([]byte, error)

type PredefinedMetricSpecification

type PredefinedMetricSpecification struct {

	// The metric type. The ALBRequestCountPerTarget metric type applies only to
	// Spot Fleet requests and ECS services.
	//
	// PredefinedMetricType is a required field
	PredefinedMetricType MetricType `type:"string" required:"true" enum:"true"`

	// 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.
	//
	// Elastic Load Balancing sends data about your load balancers to Amazon CloudWatch.
	// CloudWatch collects the data and specifies the format to use to access the
	// data. The format is app/<load-balancer-name>/<load-balancer-id>/targetgroup/<target-group-name>/<target-group-id>,
	// where:
	//
	//    * app/<load-balancer-name>/<load-balancer-id> is the final portion of
	//    the load balancer ARN
	//
	//    * targetgroup/<target-group-name>/<target-group-id> is the final portion
	//    of the target group ARN.
	//
	// To find the ARN for an Application Load Balancer, use the DescribeLoadBalancers
	// (https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html)
	// API operation. To find the ARN for the target group, use the DescribeTargetGroups
	// (https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeTargetGroups.html)
	// API operation.
	ResourceLabel *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Represents a predefined metric for a target tracking scaling policy to use with Application Auto Scaling.

Only the AWS services that you're using send metrics to Amazon CloudWatch. To determine whether a desired metric already exists by looking up its namespace and dimension using the CloudWatch metrics dashboard in the console, follow the procedure in Building Dashboards with CloudWatch (https://docs.aws.amazon.com/autoscaling/application/userguide/monitoring-cloudwatch.html) in the Application Auto Scaling User Guide.

func (PredefinedMetricSpecification) String

String returns the string representation

func (*PredefinedMetricSpecification) Validate

func (s *PredefinedMetricSpecification) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutScalingPolicyInput

type PutScalingPolicyInput struct {

	// The name of the scaling policy.
	//
	// PolicyName is a required field
	PolicyName *string `min:"1" type:"string" required:"true"`

	// 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, or Amazon
	// Keyspaces (for Apache Cassandra).
	//
	// 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)
	// in the Application Auto Scaling User Guide.
	PolicyType PolicyType `type:"string" enum:"true"`

	// The identifier of the resource associated with the scaling policy. This string
	// consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// A step scaling policy.
	//
	// This parameter is required if you are creating a policy and the policy type
	// is StepScaling.
	StepScalingPolicyConfiguration *StepScalingPolicyConfiguration `type:"structure"`

	// A target tracking scaling policy. Includes support for predefined or customized
	// metrics.
	//
	// This parameter is required if you are creating a policy and the policy type
	// is TargetTrackingScaling.
	TargetTrackingScalingPolicyConfiguration *TargetTrackingScalingPolicyConfiguration `type:"structure"`
	// contains filtered or unexported fields
}

func (PutScalingPolicyInput) String

func (s PutScalingPolicyInput) String() string

String returns the string representation

func (*PutScalingPolicyInput) Validate

func (s *PutScalingPolicyInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutScalingPolicyOutput

type PutScalingPolicyOutput struct {

	// The CloudWatch alarms created for the target tracking scaling policy.
	Alarms []Alarm `type:"list"`

	// The Amazon Resource Name (ARN) of the resulting scaling policy.
	//
	// PolicyARN is a required field
	PolicyARN *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

func (PutScalingPolicyOutput) String

func (s PutScalingPolicyOutput) String() string

String returns the string representation

type PutScalingPolicyRequest

type PutScalingPolicyRequest struct {
	*aws.Request
	Input *PutScalingPolicyInput
	Copy  func(*PutScalingPolicyInput) PutScalingPolicyRequest
}

PutScalingPolicyRequest is the request type for the PutScalingPolicy API operation.

func (PutScalingPolicyRequest) Send

Send marshals and sends the PutScalingPolicy API request.

type PutScalingPolicyResponse added in v0.9.0

type PutScalingPolicyResponse struct {
	*PutScalingPolicyOutput
	// contains filtered or unexported fields
}

PutScalingPolicyResponse is the response type for the PutScalingPolicy API operation.

func (*PutScalingPolicyResponse) SDKResponseMetdata added in v0.9.0

func (r *PutScalingPolicyResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the PutScalingPolicy request.

type PutScheduledActionInput added in v0.2.0

type PutScheduledActionInput struct {

	// The date and time for the recurring schedule to end.
	EndTime *time.Time `type:"timestamp"`

	// The identifier of the resource associated with the scheduled action. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The new minimum and maximum capacity. You can set both values or just one.
	// At the scheduled time, if the current capacity is below the minimum capacity,
	// Application Auto Scaling scales out to the minimum capacity. If the current
	// capacity is above the maximum capacity, Application Auto Scaling scales in
	// to the maximum capacity.
	ScalableTargetAction *ScalableTargetAction `type:"structure"`

	// The schedule for this action. The following formats are supported:
	//
	//    * At expressions - "at(yyyy-mm-ddThh:mm:ss)"
	//
	//    * Rate expressions - "rate(value unit)"
	//
	//    * Cron expressions - "cron(fields)"
	//
	// At expressions are useful for one-time schedules. Specify the time in UTC.
	//
	// For rate expressions, value is a positive integer and unit is minute | minutes
	// | hour | hours | day | days.
	//
	// For more information about cron expressions, see Cron Expressions (https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/ScheduledEvents.html#CronExpressions)
	// in the Amazon CloudWatch Events User Guide.
	//
	// For examples of using these expressions, see Scheduled Scaling (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scheduled-scaling.html)
	// in the Application Auto Scaling User Guide.
	Schedule *string `min:"1" type:"string"`

	// The name of the scheduled action. This name must be unique among all other
	// scheduled actions on the specified scalable target.
	//
	// ScheduledActionName is a required field
	ScheduledActionName *string `min:"1" type:"string" required:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// The date and time for this scheduled action to start.
	StartTime *time.Time `type:"timestamp"`
	// contains filtered or unexported fields
}

func (PutScheduledActionInput) String added in v0.2.0

func (s PutScheduledActionInput) String() string

String returns the string representation

func (*PutScheduledActionInput) Validate added in v0.2.0

func (s *PutScheduledActionInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type PutScheduledActionOutput added in v0.2.0

type PutScheduledActionOutput struct {
	// contains filtered or unexported fields
}

func (PutScheduledActionOutput) String added in v0.2.0

func (s PutScheduledActionOutput) String() string

String returns the string representation

type PutScheduledActionRequest added in v0.2.0

type PutScheduledActionRequest struct {
	*aws.Request
	Input *PutScheduledActionInput
	Copy  func(*PutScheduledActionInput) PutScheduledActionRequest
}

PutScheduledActionRequest is the request type for the PutScheduledAction API operation.

func (PutScheduledActionRequest) Send added in v0.2.0

Send marshals and sends the PutScheduledAction API request.

type PutScheduledActionResponse added in v0.9.0

type PutScheduledActionResponse struct {
	*PutScheduledActionOutput
	// contains filtered or unexported fields
}

PutScheduledActionResponse is the response type for the PutScheduledAction API operation.

func (*PutScheduledActionResponse) SDKResponseMetdata added in v0.9.0

func (r *PutScheduledActionResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the PutScheduledAction request.

type RegisterScalableTargetInput

type RegisterScalableTargetInput struct {

	// The maximum value that you plan to scale out to. When a scaling policy is
	// in effect, Application Auto Scaling can scale out (expand) as needed to the
	// maximum capacity limit in response to changing demand.
	//
	// This parameter is required if you are registering a scalable target.
	MaxCapacity *int64 `type:"integer"`

	// 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 parameter is required if you are registering a 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.
	MinCapacity *int64 `type:"integer"`

	// The identifier of the resource that is associated with the scalable target.
	// This string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// This parameter is required for services that do not support service-linked
	// roles (such as Amazon EMR), and it must specify the ARN of an IAM role that
	// allows Application Auto Scaling to modify the scalable target on your behalf.
	//
	// If the service supports service-linked roles, Application Auto Scaling uses
	// a service-linked role, which it creates if it does not yet exist. For more
	// information, see Application Auto Scaling IAM Roles (https://docs.aws.amazon.com/autoscaling/application/userguide/security_iam_service-with-iam.html#security_iam_service-with-iam-roles).
	RoleARN *string `min:"1" type:"string"`

	// The scalable dimension associated with the scalable target. This string consists
	// of the service namespace, resource type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource. For a resource
	// provided by your own application or service, use custom-resource instead.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// An embedded object that contains attributes and attribute values that are
	// used to suspend and resume automatic scaling. Setting the value of an attribute
	// to true suspends the specified scaling activities. Setting it to false (default)
	// resumes the specified scaling activities.
	//
	// Suspension Outcomes
	//
	//    * For DynamicScalingInSuspended, while a suspension is in effect, all
	//    scale-in activities that are triggered by a scaling policy are suspended.
	//
	//    * For DynamicScalingOutSuspended, while a suspension is in effect, all
	//    scale-out activities that are triggered by a scaling policy are suspended.
	//
	//    * For ScheduledScalingSuspended, while a suspension is in effect, all
	//    scaling activities that involve scheduled actions are suspended.
	//
	// For more information, see Suspending and Resuming Scaling (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-suspend-resume-scaling.html)
	// in the Application Auto Scaling User Guide.
	SuspendedState *SuspendedState `type:"structure"`
	// contains filtered or unexported fields
}

func (RegisterScalableTargetInput) String

String returns the string representation

func (*RegisterScalableTargetInput) Validate

func (s *RegisterScalableTargetInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type RegisterScalableTargetOutput

type RegisterScalableTargetOutput struct {
	// contains filtered or unexported fields
}

func (RegisterScalableTargetOutput) String

String returns the string representation

type RegisterScalableTargetRequest

type RegisterScalableTargetRequest struct {
	*aws.Request
	Input *RegisterScalableTargetInput
	Copy  func(*RegisterScalableTargetInput) RegisterScalableTargetRequest
}

RegisterScalableTargetRequest is the request type for the RegisterScalableTarget API operation.

func (RegisterScalableTargetRequest) Send

Send marshals and sends the RegisterScalableTarget API request.

type RegisterScalableTargetResponse added in v0.9.0

type RegisterScalableTargetResponse struct {
	*RegisterScalableTargetOutput
	// contains filtered or unexported fields
}

RegisterScalableTargetResponse is the response type for the RegisterScalableTarget API operation.

func (*RegisterScalableTargetResponse) SDKResponseMetdata added in v0.9.0

func (r *RegisterScalableTargetResponse) SDKResponseMetdata() *aws.Response

SDKResponseMetdata returns the response metadata for the RegisterScalableTarget request.

type ScalableDimension

type ScalableDimension string
const (
	ScalableDimensionEcsServiceDesiredCount                                    ScalableDimension = "ecs:service:DesiredCount"
	ScalableDimensionEc2SpotFleetRequestTargetCapacity                         ScalableDimension = "ec2:spot-fleet-request:TargetCapacity"
	ScalableDimensionElasticmapreduceInstancegroupInstanceCount                ScalableDimension = "elasticmapreduce:instancegroup:InstanceCount"
	ScalableDimensionAppstreamFleetDesiredCapacity                             ScalableDimension = "appstream:fleet:DesiredCapacity"
	ScalableDimensionDynamodbTableReadCapacityUnits                            ScalableDimension = "dynamodb:table:ReadCapacityUnits"
	ScalableDimensionDynamodbTableWriteCapacityUnits                           ScalableDimension = "dynamodb:table:WriteCapacityUnits"
	ScalableDimensionDynamodbIndexReadCapacityUnits                            ScalableDimension = "dynamodb:index:ReadCapacityUnits"
	ScalableDimensionDynamodbIndexWriteCapacityUnits                           ScalableDimension = "dynamodb:index:WriteCapacityUnits"
	ScalableDimensionRdsClusterReadReplicaCount                                ScalableDimension = "rds:cluster:ReadReplicaCount"
	ScalableDimensionSagemakerVariantDesiredInstanceCount                      ScalableDimension = "sagemaker:variant:DesiredInstanceCount"
	ScalableDimensionCustomResourceResourceTypeProperty                        ScalableDimension = "custom-resource:ResourceType:Property"
	ScalableDimensionComprehendDocumentClassifierEndpointDesiredInferenceUnits ScalableDimension = "comprehend:document-classifier-endpoint:DesiredInferenceUnits"
	ScalableDimensionLambdaFunctionProvisionedConcurrency                      ScalableDimension = "lambda:function:ProvisionedConcurrency"
	ScalableDimensionCassandraTableReadCapacityUnits                           ScalableDimension = "cassandra:table:ReadCapacityUnits"
	ScalableDimensionCassandraTableWriteCapacityUnits                          ScalableDimension = "cassandra:table:WriteCapacityUnits"
)

Enum values for ScalableDimension

func (ScalableDimension) MarshalValue added in v0.3.0

func (enum ScalableDimension) MarshalValue() (string, error)

func (ScalableDimension) MarshalValueBuf added in v0.3.0

func (enum ScalableDimension) MarshalValueBuf(b []byte) ([]byte, error)

type ScalableTarget

type ScalableTarget struct {

	// The Unix timestamp for when the scalable target was created.
	//
	// CreationTime is a required field
	CreationTime *time.Time `type:"timestamp" required:"true"`

	// The maximum value to scale to in response to a scale-out activity.
	//
	// MaxCapacity is a required field
	MaxCapacity *int64 `type:"integer" required:"true"`

	// The minimum value to scale to in response to a scale-in activity.
	//
	// MinCapacity is a required field
	MinCapacity *int64 `type:"integer" required:"true"`

	// The identifier of the resource associated with the scalable target. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The ARN of an IAM role that allows Application Auto Scaling to modify the
	// scalable target on your behalf.
	//
	// RoleARN is a required field
	RoleARN *string `min:"1" type:"string" required:"true"`

	// The scalable dimension associated with the scalable target. This string consists
	// of the service namespace, resource type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource, or a custom-resource.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// Specifies whether the scaling activities for a scalable target are in a suspended
	// state.
	SuspendedState *SuspendedState `type:"structure"`
	// contains filtered or unexported fields
}

Represents a scalable target.

func (ScalableTarget) String

func (s ScalableTarget) String() string

String returns the string representation

type ScalableTargetAction added in v0.2.0

type ScalableTargetAction struct {

	// The maximum capacity.
	MaxCapacity *int64 `type:"integer"`

	// The minimum capacity.
	//
	// For Lambda provisioned concurrency, the minimum value allowed is 0. For all
	// other resources, the minimum value allowed is 1.
	MinCapacity *int64 `type:"integer"`
	// contains filtered or unexported fields
}

Represents the minimum and maximum capacity for a scheduled action.

func (ScalableTargetAction) String added in v0.2.0

func (s ScalableTargetAction) String() string

String returns the string representation

type ScalingActivity

type ScalingActivity struct {

	// The unique identifier of the scaling activity.
	//
	// ActivityId is a required field
	ActivityId *string `type:"string" required:"true"`

	// A simple description of what caused the scaling activity to happen.
	//
	// Cause is a required field
	Cause *string `type:"string" required:"true"`

	// A simple description of what action the scaling activity intends to accomplish.
	//
	// Description is a required field
	Description *string `type:"string" required:"true"`

	// The details about the scaling activity.
	Details *string `type:"string"`

	// The Unix timestamp for when the scaling activity ended.
	EndTime *time.Time `type:"timestamp"`

	// The identifier of the resource associated with the scaling activity. This
	// string consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource, or a custom-resource.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// The Unix timestamp for when the scaling activity began.
	//
	// StartTime is a required field
	StartTime *time.Time `type:"timestamp" required:"true"`

	// Indicates the status of the scaling activity.
	//
	// StatusCode is a required field
	StatusCode ScalingActivityStatusCode `type:"string" required:"true" enum:"true"`

	// A simple message about the current status of the scaling activity.
	StatusMessage *string `type:"string"`
	// contains filtered or unexported fields
}

Represents a scaling activity.

func (ScalingActivity) String

func (s ScalingActivity) String() string

String returns the string representation

type ScalingActivityStatusCode

type ScalingActivityStatusCode string
const (
	ScalingActivityStatusCodePending     ScalingActivityStatusCode = "Pending"
	ScalingActivityStatusCodeInProgress  ScalingActivityStatusCode = "InProgress"
	ScalingActivityStatusCodeSuccessful  ScalingActivityStatusCode = "Successful"
	ScalingActivityStatusCodeOverridden  ScalingActivityStatusCode = "Overridden"
	ScalingActivityStatusCodeUnfulfilled ScalingActivityStatusCode = "Unfulfilled"
	ScalingActivityStatusCodeFailed      ScalingActivityStatusCode = "Failed"
)

Enum values for ScalingActivityStatusCode

func (ScalingActivityStatusCode) MarshalValue added in v0.3.0

func (enum ScalingActivityStatusCode) MarshalValue() (string, error)

func (ScalingActivityStatusCode) MarshalValueBuf added in v0.3.0

func (enum ScalingActivityStatusCode) MarshalValueBuf(b []byte) ([]byte, error)

type ScalingPolicy

type ScalingPolicy struct {

	// The CloudWatch alarms associated with the scaling policy.
	Alarms []Alarm `type:"list"`

	// The Unix timestamp for when the scaling policy was created.
	//
	// CreationTime is a required field
	CreationTime *time.Time `type:"timestamp" required:"true"`

	// The Amazon Resource Name (ARN) of the scaling policy.
	//
	// PolicyARN is a required field
	PolicyARN *string `min:"1" type:"string" required:"true"`

	// The name of the scaling policy.
	//
	// PolicyName is a required field
	PolicyName *string `min:"1" type:"string" required:"true"`

	// The scaling policy type.
	//
	// PolicyType is a required field
	PolicyType PolicyType `type:"string" required:"true" enum:"true"`

	// The identifier of the resource associated with the scaling policy. This string
	// consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	//
	// ScalableDimension is a required field
	ScalableDimension ScalableDimension `type:"string" required:"true" enum:"true"`

	// The namespace of the AWS service that provides the resource, or a custom-resource.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// A step scaling policy.
	StepScalingPolicyConfiguration *StepScalingPolicyConfiguration `type:"structure"`

	// A target tracking scaling policy.
	TargetTrackingScalingPolicyConfiguration *TargetTrackingScalingPolicyConfiguration `type:"structure"`
	// contains filtered or unexported fields
}

Represents a scaling policy to use with Application Auto Scaling.

func (ScalingPolicy) String

func (s ScalingPolicy) String() string

String returns the string representation

type ScheduledAction added in v0.2.0

type ScheduledAction struct {

	// The date and time that the scheduled action was created.
	//
	// CreationTime is a required field
	CreationTime *time.Time `type:"timestamp" required:"true"`

	// The date and time that the action is scheduled to end.
	EndTime *time.Time `type:"timestamp"`

	// The identifier of the resource associated with the scaling policy. This string
	// consists of the resource type and unique identifier.
	//
	//    * ECS service - The resource type is service and the unique identifier
	//    is the cluster name and service name. Example: service/default/sample-webapp.
	//
	//    * Spot Fleet request - The resource type is spot-fleet-request and the
	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
	//
	//    * EMR cluster - The resource type is instancegroup and the unique identifier
	//    is the cluster ID and instance group ID. Example: instancegroup/j-2EEZNYKUA1NTV/ig-1791Y4E1L8YI0.
	//
	//    * AppStream 2.0 fleet - The resource type is fleet and the unique identifier
	//    is the fleet name. Example: fleet/sample-fleet.
	//
	//    * DynamoDB table - The resource type is table and the unique identifier
	//    is the table name. Example: table/my-table.
	//
	//    * DynamoDB global secondary index - The resource type is index and the
	//    unique identifier is the index name. Example: table/my-table/index/my-table-index.
	//
	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
	//    is the cluster name. Example: cluster:my-db-cluster.
	//
	//    * Amazon SageMaker endpoint variant - The resource type is variant and
	//    the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering.
	//
	//    * Custom resources are not supported with a resource type. This parameter
	//    must specify the OutputValue from the CloudFormation template stack used
	//    to access the resources. The unique identifier is defined by the service
	//    provider. More information is available in our GitHub repository (https://github.com/aws/aws-auto-scaling-custom-resource).
	//
	//    * Amazon Comprehend document classification endpoint - The resource type
	//    and unique identifier are specified using the endpoint ARN. Example: arn:aws:comprehend:us-west-2:123456789012:document-classifier-endpoint/EXAMPLE.
	//
	//    * Lambda provisioned concurrency - The resource type is function and the
	//    unique identifier is the function name with a function version or alias
	//    name suffix that is not $LATEST. Example: function:my-function:prod or
	//    function:my-function:1.
	//
	//    * Amazon Keyspaces table - The resource type is table and the unique identifier
	//    is the table name. Example: keyspace/mykeyspace/table/mytable.
	//
	// ResourceId is a required field
	ResourceId *string `min:"1" type:"string" required:"true"`

	// The scalable dimension. This string consists of the service namespace, resource
	// type, and scaling property.
	//
	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
	//
	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
	//    Fleet request.
	//
	//    * elasticmapreduce:instancegroup:InstanceCount - The instance count of
	//    an EMR Instance Group.
	//
	//    * appstream:fleet:DesiredCapacity - The desired capacity of an AppStream
	//    2.0 fleet.
	//
	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB table.
	//
	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
	//    a DynamoDB global secondary index.
	//
	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
	//    a DynamoDB global secondary index.
	//
	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
	//    edition.
	//
	//    * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances
	//    for an Amazon SageMaker model endpoint variant.
	//
	//    * custom-resource:ResourceType:Property - The scalable dimension for a
	//    custom resource provided by your own application or service.
	//
	//    * comprehend:document-classifier-endpoint:DesiredInferenceUnits - The
	//    number of inference units for an Amazon Comprehend document classification
	//    endpoint.
	//
	//    * lambda:function:ProvisionedConcurrency - The provisioned concurrency
	//    for a Lambda function.
	//
	//    * cassandra:table:ReadCapacityUnits - The provisioned read capacity for
	//    an Amazon Keyspaces table.
	//
	//    * cassandra:table:WriteCapacityUnits - The provisioned write capacity
	//    for an Amazon Keyspaces table.
	ScalableDimension ScalableDimension `type:"string" enum:"true"`

	// The new minimum and maximum capacity. You can set both values or just one.
	// At the scheduled time, if the current capacity is below the minimum capacity,
	// Application Auto Scaling scales out to the minimum capacity. If the current
	// capacity is above the maximum capacity, Application Auto Scaling scales in
	// to the maximum capacity.
	ScalableTargetAction *ScalableTargetAction `type:"structure"`

	// The schedule for this action. The following formats are supported:
	//
	//    * At expressions - "at(yyyy-mm-ddThh:mm:ss)"
	//
	//    * Rate expressions - "rate(value unit)"
	//
	//    * Cron expressions - "cron(fields)"
	//
	// At expressions are useful for one-time schedules. Specify the time in UTC.
	//
	// For rate expressions, value is a positive integer and unit is minute | minutes
	// | hour | hours | day | days.
	//
	// For more information about cron expressions, see Cron Expressions (https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/ScheduledEvents.html#CronExpressions)
	// in the Amazon CloudWatch Events User Guide.
	//
	// For examples of using these expressions, see Scheduled Scaling (https://docs.aws.amazon.com/autoscaling/application/userguide/application-auto-scaling-scheduled-scaling.html)
	// in the Application Auto Scaling User Guide.
	//
	// Schedule is a required field
	Schedule *string `min:"1" type:"string" required:"true"`

	// The Amazon Resource Name (ARN) of the scheduled action.
	//
	// ScheduledActionARN is a required field
	ScheduledActionARN *string `min:"1" type:"string" required:"true"`

	// The name of the scheduled action.
	//
	// ScheduledActionName is a required field
	ScheduledActionName *string `min:"1" type:"string" required:"true"`

	// The namespace of the AWS service that provides the resource, or a custom-resource.
	//
	// ServiceNamespace is a required field
	ServiceNamespace ServiceNamespace `type:"string" required:"true" enum:"true"`

	// The date and time that the action is scheduled to begin.
	StartTime *time.Time `type:"timestamp"`
	// contains filtered or unexported fields
}

Represents a scheduled action.

func (ScheduledAction) String added in v0.2.0

func (s ScheduledAction) String() string

String returns the string representation

type ServiceNamespace

type ServiceNamespace string
const (
	ServiceNamespaceEcs              ServiceNamespace = "ecs"
	ServiceNamespaceElasticmapreduce ServiceNamespace = "elasticmapreduce"
	ServiceNamespaceEc2              ServiceNamespace = "ec2"
	ServiceNamespaceAppstream        ServiceNamespace = "appstream"
	ServiceNamespaceDynamodb         ServiceNamespace = "dynamodb"
	ServiceNamespaceRds              ServiceNamespace = "rds"
	ServiceNamespaceSagemaker        ServiceNamespace = "sagemaker"
	ServiceNamespaceCustomResource   ServiceNamespace = "custom-resource"
	ServiceNamespaceComprehend       ServiceNamespace = "comprehend"
	ServiceNamespaceLambda           ServiceNamespace = "lambda"
	ServiceNamespaceCassandra        ServiceNamespace = "cassandra"
)

Enum values for ServiceNamespace

func (ServiceNamespace) MarshalValue added in v0.3.0

func (enum ServiceNamespace) MarshalValue() (string, error)

func (ServiceNamespace) MarshalValueBuf added in v0.3.0

func (enum ServiceNamespace) MarshalValueBuf(b []byte) ([]byte, error)

type StepAdjustment

type StepAdjustment struct {

	// The lower bound for the difference between the alarm threshold and the CloudWatch
	// metric. If the metric value is above the breach threshold, the lower bound
	// is inclusive (the metric must be greater than or equal to the threshold plus
	// the lower bound). Otherwise, it is exclusive (the metric must be greater
	// than the threshold plus the lower bound). A null value indicates negative
	// infinity.
	MetricIntervalLowerBound *float64 `type:"double"`

	// The upper bound for the difference between the alarm threshold and the CloudWatch
	// metric. If the metric value is above the breach threshold, the upper bound
	// is exclusive (the metric must be less than the threshold plus the upper bound).
	// Otherwise, it is inclusive (the metric must be less than or equal to the
	// threshold plus the upper bound). A null value indicates positive infinity.
	//
	// The upper bound must be greater than the lower bound.
	MetricIntervalUpperBound *float64 `type:"double"`

	// The amount by which to scale, based on the specified adjustment type. A positive
	// value adds to the current capacity while a negative number removes from the
	// current capacity.
	//
	// ScalingAdjustment is a required field
	ScalingAdjustment *int64 `type:"integer" required:"true"`
	// contains filtered or unexported fields
}

Represents a step adjustment for a StepScalingPolicyConfiguration (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_StepScalingPolicyConfiguration.html). Describes an adjustment based on the difference between the value of the aggregated CloudWatch metric and the breach threshold that you've defined for the alarm.

For the following examples, suppose that you have an alarm with a breach threshold of 50:

  • To trigger the adjustment when the metric is greater than or equal to 50 and less than 60, specify a lower bound of 0 and an upper bound of 10.

  • To trigger the adjustment when the metric is greater than 40 and less than or equal to 50, specify a lower bound of -10 and an upper bound of 0.

There are a few rules for the step adjustments for your step policy:

  • The ranges of your step adjustments can't overlap or have a gap.

  • At most one step adjustment can have a null lower bound. If one step adjustment has a negative lower bound, then there must be a step adjustment with a null lower bound.

  • At most one step adjustment can have a null upper bound. If one step adjustment has a positive upper bound, then there must be a step adjustment with a null upper bound.

  • The upper and lower bound can't be null in the same step adjustment.

func (StepAdjustment) String

func (s StepAdjustment) String() string

String returns the string representation

func (*StepAdjustment) Validate

func (s *StepAdjustment) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type StepScalingPolicyConfiguration

type StepScalingPolicyConfiguration struct {

	// Specifies whether the ScalingAdjustment value in a StepAdjustment (https://docs.aws.amazon.com/autoscaling/application/APIReference/API_StepAdjustment.html)
	// is an absolute number or a percentage of the current capacity.
	//
	// AdjustmentType is required if you are adding a new step scaling policy configuration.
	AdjustmentType AdjustmentType `type:"string" enum:"true"`

	// The amount of time, in seconds, to wait for a previous scaling activity to
	// take effect.
	//
	// With scale-out policies, the intention is to continuously (but not excessively)
	// scale out. After Application Auto Scaling successfully scales out using a
	// step scaling policy, it starts to calculate the cooldown time. While the
	// cooldown period is in effect, capacity added by the initiating scale-out
	// activity is calculated as part of the desired capacity for the next scale-out
	// activity. For example, when an alarm triggers a step scaling policy to increase
	// the capacity by 2, the scaling activity completes successfully, and a cooldown
	// period starts. If the alarm triggers again during the cooldown period but
	// at a more aggressive step adjustment of 3, the previous increase of 2 is
	// considered part of the current capacity. Therefore, only 1 is added to the
	// capacity.
	//
	// With scale-in policies, the intention is to scale in conservatively to protect
	// your application’s availability, so scale-in activities are blocked until
	// the cooldown period has expired. However, if another alarm triggers a scale-out
	// activity during the cooldown period after a scale-in activity, Application
	// Auto Scaling scales out the target immediately. In this case, the cooldown
	// period for the scale-in activity stops and doesn't complete.
	//
	// Application Auto Scaling provides a default value of 300 for the following
	// scalable targets:
	//
	//    * ECS services
	//
	//    * Spot Fleet requests
	//
	//    * EMR clusters
	//
	//    * AppStream 2.0 fleets
	//
	//    * Aurora DB clusters
	//
	//    * Amazon SageMaker endpoint variants
	//
	//    * Custom resources
	//
	// For all other scalable targets, the default value is 0:
	//
	//    * DynamoDB tables
	//
	//    * DynamoDB global secondary indexes
	//
	//    * Amazon Comprehend document classification endpoints
	//
	//    * Lambda provisioned concurrency
	//
	//    * Amazon Keyspaces tables
	Cooldown *int64 `type:"integer"`

	// The aggregation type for the CloudWatch metrics. Valid values are Minimum,
	// Maximum, and Average. If the aggregation type is null, the value is treated
	// as Average.
	MetricAggregationType MetricAggregationType `type:"string" enum:"true"`

	// The minimum value to scale by when scaling by percentages. For example, suppose
	// that you create a step scaling policy to scale out an Amazon ECS service
	// by 25 percent and you specify a MinAdjustmentMagnitude of 2. If the service
	// has 4 tasks and the scaling policy is performed, 25 percent of 4 is 1. However,
	// because you specified a MinAdjustmentMagnitude of 2, Application Auto Scaling
	// scales out the service by 2 tasks.
	//
	// Valid only if the adjustment type is PercentChangeInCapacity.
	MinAdjustmentMagnitude *int64 `type:"integer"`

	// A set of adjustments that enable you to scale based on the size of the alarm
	// breach.
	//
	// At least one step adjustment is required if you are adding a new step scaling
	// policy configuration.
	StepAdjustments []StepAdjustment `type:"list"`
	// contains filtered or unexported fields
}

Represents a step scaling policy configuration to use with Application Auto Scaling.

func (StepScalingPolicyConfiguration) String

String returns the string representation

func (*StepScalingPolicyConfiguration) Validate

func (s *StepScalingPolicyConfiguration) Validate() error

Validate inspects the fields of the type to determine if they are valid.

type SuspendedState added in v0.12.0

type SuspendedState struct {

	// Whether scale in by a target tracking scaling policy or a step scaling policy
	// is suspended. Set the value to true if you don't want Application Auto Scaling
	// to remove capacity when a scaling policy is triggered. The default is false.
	DynamicScalingInSuspended *bool `type:"boolean"`

	// Whether scale out by a target tracking scaling policy or a step scaling policy
	// is suspended. Set the value to true if you don't want Application Auto Scaling
	// to add capacity when a scaling policy is triggered. The default is false.
	DynamicScalingOutSuspended *bool `type:"boolean"`

	// Whether scheduled scaling is suspended. Set the value to true if you don't
	// want Application Auto Scaling to add or remove capacity by initiating scheduled
	// actions. The default is false.
	ScheduledScalingSuspended *bool `type:"boolean"`
	// contains filtered or unexported fields
}

Specifies whether the scaling activities for a scalable target are in a suspended state.

func (SuspendedState) String added in v0.12.0

func (s SuspendedState) String() string

String returns the string representation

type TargetTrackingScalingPolicyConfiguration

type TargetTrackingScalingPolicyConfiguration struct {

	// A customized metric. You can specify either a predefined metric or a customized
	// metric.
	CustomizedMetricSpecification *CustomizedMetricSpecification `type:"structure"`

	// Indicates whether scale in by the target tracking scaling policy is disabled.
	// If the value is true, scale in is disabled and the target tracking scaling
	// policy won't remove capacity from the scalable target. Otherwise, scale in
	// is enabled and the target tracking scaling policy can remove capacity from
	// the scalable target. The default value is false.
	DisableScaleIn *bool `type:"boolean"`

	// A predefined metric. You can specify either a predefined metric or a customized
	// metric.
	PredefinedMetricSpecification *PredefinedMetricSpecification `type:"structure"`

	// The amount of time, in seconds, after a scale-in activity completes before
	// another scale-in activity can start.
	//
	// With the scale-in cooldown period, the intention is to scale in conservatively
	// to protect your application’s availability, so scale-in activities are
	// blocked until the cooldown period has expired. However, if another alarm
	// triggers a scale-out activity during the scale-in cooldown period, Application
	// Auto Scaling scales out the target immediately. In this case, the scale-in
	// cooldown period stops and doesn't complete.
	//
	// Application Auto Scaling provides a default value of 300 for the following
	// scalable targets:
	//
	//    * ECS services
	//
	//    * Spot Fleet requests
	//
	//    * EMR clusters
	//
	//    * AppStream 2.0 fleets
	//
	//    * Aurora DB clusters
	//
	//    * Amazon SageMaker endpoint variants
	//
	//    * Custom resources
	//
	// For all other scalable targets, the default value is 0:
	//
	//    * DynamoDB tables
	//
	//    * DynamoDB global secondary indexes
	//
	//    * Amazon Comprehend document classification endpoints
	//
	//    * Lambda provisioned concurrency
	//
	//    * Amazon Keyspaces tables
	ScaleInCooldown *int64 `type:"integer"`

	// The amount of time, in seconds, to wait for a previous scale-out activity
	// to take effect.
	//
	// With the scale-out cooldown period, the intention is to continuously (but
	// not excessively) scale out. After Application Auto Scaling successfully scales
	// out using a target tracking scaling policy, it starts to calculate the cooldown
	// time. While the scale-out cooldown period is in effect, the capacity added
	// by the initiating scale-out activity is calculated as part of the desired
	// capacity for the next scale-out activity.
	//
	// Application Auto Scaling provides a default value of 300 for the following
	// scalable targets:
	//
	//    * ECS services
	//
	//    * Spot Fleet requests
	//
	//    * EMR clusters
	//
	//    * AppStream 2.0 fleets
	//
	//    * Aurora DB clusters
	//
	//    * Amazon SageMaker endpoint variants
	//
	//    * Custom resources
	//
	// For all other scalable targets, the default value is 0:
	//
	//    * DynamoDB tables
	//
	//    * DynamoDB global secondary indexes
	//
	//    * Amazon Comprehend document classification endpoints
	//
	//    * Lambda provisioned concurrency
	//
	//    * Amazon Keyspaces tables
	ScaleOutCooldown *int64 `type:"integer"`

	// The target value for the metric. The range is 8.515920e-109 to 1.174271e+108
	// (Base 10) or 2e-360 to 2e360 (Base 2).
	//
	// TargetValue is a required field
	TargetValue *float64 `type:"double" required:"true"`
	// contains filtered or unexported fields
}

Represents a target tracking scaling policy configuration to use with Application Auto Scaling.

func (TargetTrackingScalingPolicyConfiguration) String

String returns the string representation

func (*TargetTrackingScalingPolicyConfiguration) Validate

Validate inspects the fields of the type to determine if they are valid.

Directories

Path Synopsis
Package applicationautoscalingiface provides an interface to enable mocking the Application Auto Scaling service client for testing your code.
Package applicationautoscalingiface provides an interface to enable mocking the Application Auto Scaling service client for testing your code.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL