Skip to content
v2.278.0

AutoScalingSettingProperty Struct ​

The optional auto scaling settings for a table with provisioned throughput capacity.

To turn on auto scaling for a table in throughputMode:PROVISIONED , you must specify the following parameters.

Configure the minimum and maximum capacity units. The auto scaling policy ensures that capacity never goes below the minimum or above the maximum range.

  • minimumUnits : The minimum level of throughput the table should always be ready to support. The value must be between 1 and the max throughput per second quota for your account (40,000 by default).
  • maximumUnits : The maximum level of throughput the table should always be ready to support. The value must be between 1 and the max throughput per second quota for your account (40,000 by default).
  • scalingPolicy : Amazon Keyspaces supports the target tracking scaling policy. The auto scaling target is a percentage of the provisioned capacity of the table.

For more information, see Managing throughput capacity automatically with Amazon Keyspaces auto scaling in the Amazon Keyspaces Developer Guide .

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cassandra as cassandra } from 'aws-cdk-lib';
const autoScalingSettingProperty: cassandra.CfnTable.AutoScalingSettingProperty = {
  autoScalingDisabled: false,
  maximumUnits: 123,
  minimumUnits: 123,
  scalingPolicy: {
    targetTrackingScalingPolicyConfiguration: {
      targetValue: 123,

      // the properties below are optional
      disableScaleIn: false,
      scaleInCooldown: 123,
      scaleOutCooldown: 123,
    },
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_cassandra as cassandra

auto_scaling_setting_property = cassandra.CfnTable.AutoScalingSettingProperty(
    auto_scaling_disabled=False,
    maximum_units=123,
    minimum_units=123,
    scaling_policy=cassandra.CfnTable.ScalingPolicyProperty(
        target_tracking_scaling_policy_configuration=cassandra.CfnTable.TargetTrackingScalingPolicyConfigurationProperty(
            target_value=123,

            # the properties below are optional
            disable_scale_in=False,
            scale_in_cooldown=123,
            scale_out_cooldown=123
        )
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.cassandra.*;

AutoScalingSettingProperty autoScalingSettingProperty = AutoScalingSettingProperty.builder()
        .autoScalingDisabled(false)
        .maximumUnits(123)
        .minimumUnits(123)
        .scalingPolicy(ScalingPolicyProperty.builder()
                .targetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfigurationProperty.builder()
                        .targetValue(123)

                        // the properties below are optional
                        .disableScaleIn(false)
                        .scaleInCooldown(123)
                        .scaleOutCooldown(123)
                        .build())
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Cassandra;

var autoScalingSettingProperty = new AutoScalingSettingProperty {
    AutoScalingDisabled = false,
    MaximumUnits = 123,
    MinimumUnits = 123,
    ScalingPolicy = new ScalingPolicyProperty {
        TargetTrackingScalingPolicyConfiguration = new TargetTrackingScalingPolicyConfigurationProperty {
            TargetValue = 123,

            // the properties below are optional
            DisableScaleIn = false,
            ScaleInCooldown = 123,
            ScaleOutCooldown = 123
        }
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

autoScalingSettingProperty := &AutoScalingSettingProperty{
	AutoScalingDisabled: jsii.Boolean(false),
	MaximumUnits: jsii.Number(123),
	MinimumUnits: jsii.Number(123),
	ScalingPolicy: &ScalingPolicyProperty{
		TargetTrackingScalingPolicyConfiguration: &TargetTrackingScalingPolicyConfigurationProperty{
			TargetValue: jsii.Number(123),

			// the properties below are optional
			DisableScaleIn: jsii.Boolean(false),
			ScaleInCooldown: jsii.Number(123),
			ScaleOutCooldown: jsii.Number(123),
		},
	},
}

Properties ​

autoScalingDisabledoptionalboolean | IResolvableauto_scaling_disabledoptionaltyping.Union[bool, IResolvable]autoScalingDisabledoptionalBooleanAutoScalingDisabledoptionalboolAutoScalingDisabledoptionalinterface{} = false #
This optional parameter enables auto scaling for the table if set to `false` .
maximumUnitsoptionalnumbermaximum_unitsoptionalint | floatmaximumUnitsoptionalNumberMaximumUnitsoptionaldoubleMaximumUnitsoptional*float64 #
Manage costs by specifying the maximum amount of throughput to provision.

The value must be between 1 and the max throughput per second quota for your account (40,000 by default).

minimumUnitsoptionalnumberminimum_unitsoptionalint | floatminimumUnitsoptionalNumberMinimumUnitsoptionaldoubleMinimumUnitsoptional*float64 #
The minimum level of throughput the table should always be ready to support.

The value must be between 1 and the max throughput per second quota for your account (40,000 by default).

scalingPolicyoptionalIResolvable | CfnTable.ScalingPolicyPropertyscaling_policyoptionaltyping.Union[IResolvable, ScalingPolicyProperty]scalingPolicyoptionalIResolvableScalingPolicyoptionalIResolvableScalingPolicyoptionalinterface{} #
Amazon Keyspaces supports the `target tracking` auto scaling policy.

With this policy, Amazon Keyspaces auto scaling ensures that the table's ratio of consumed to provisioned capacity stays at or near the target value that you specify. You define the target value as a percentage between 20 and 90.