aws-cdk-lib.aws_ecs.ScalableTaskCountProps

interface ScalableTaskCountProps

LanguageType name
.NETAmazon.CDK.AWS.ECS.ScalableTaskCountProps
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsecs#ScalableTaskCountProps
Javasoftware.amazon.awscdk.services.ecs.ScalableTaskCountProps
Pythonaws_cdk.aws_ecs.ScalableTaskCountProps
TypeScript (source)aws-cdk-lib » aws_ecs » ScalableTaskCountProps

The properties of a scalable attribute representing task count.

Example

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_applicationautoscaling as appscaling } from 'aws-cdk-lib';
import { aws_ecs as ecs } from 'aws-cdk-lib';
import { aws_iam as iam } from 'aws-cdk-lib';

declare const role: iam.Role;
const scalableTaskCountProps: ecs.ScalableTaskCountProps = {
  dimension: 'dimension',
  maxCapacity: 123,
  resourceId: 'resourceId',
  role: role,
  serviceNamespace: appscaling.ServiceNamespace.ECS,

  // the properties below are optional
  minCapacity: 123,
};

Properties

NameTypeDescription
dimensionstringScalable dimension of the attribute.
maxCapacitynumberMaximum capacity to scale to.
resourceIdstringResource ID of the attribute.
roleIRoleRole to use for scaling.
serviceNamespaceServiceNamespaceService namespace of the scalable attribute.
minCapacity?numberMinimum capacity to scale to.

dimension

Type: string

Scalable dimension of the attribute.


maxCapacity

Type: number

Maximum capacity to scale to.


resourceId

Type: string

Resource ID of the attribute.


role

Type: IRole

Role to use for scaling.


serviceNamespace

Type: ServiceNamespace

Service namespace of the scalable attribute.


minCapacity?

Type: number (optional, default: 1)

Minimum capacity to scale to.