Define a scalable target.
import { ScalableTarget } from 'aws-cdk-lib/aws-applicationautoscaling';Or use the module namespace:
import * as applicationautoscaling from 'aws-cdk-lib/aws-applicationautoscaling';
// applicationautoscaling.ScalableTargetConfiguration passed to the constructor as ScalableTargetProps.
maxCapacityRequirednumberThe maximum value that Application Auto Scaling can use to scale a target during a scaling activity.
minCapacityRequirednumberThe minimum value that Application Auto Scaling can use to scale a target during a scaling activity.
resourceIdRequiredstringThe resource identifier to associate with this scalable target. This string consists of the resource type and unique identifier. Example value: `service/ecsStack-MyECSCluster-AB12CDE3F4GH/ecsStack-MyECSService-AB12CDE3F4GH`
scalableDimensionRequiredstringThe scalable dimension that's associated with the scalable target. Specify the service namespace, resource type, and scaling property. Example value: `ecs:service:DesiredCount`
serviceNamespaceRequiredServiceNamespaceThe namespace of the AWS service that provides the resource or custom-resource for a resource provided by your own application or service. For valid AWS service namespace values, see the RegisterScalableTarget action in the Application Auto Scaling API Reference.
roleOptionalIRoleRole that allows Application Auto Scaling to modify your scalable target.
Default: A role is automatically created
Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.
Subscribe to Newsletteraws-applicationautoscaling