ScalingActionProperty Struct
The type of adjustment the automatic scaling activity makes when triggered, and the periodicity of the adjustment.
And an automatic scaling configuration, which describes how the policy adds or removes instances, the cooldown period, and the number of EC2 instances that will be added each time the CloudWatch metric alarm condition is satisfied.
| Source | aws-stepfunctions-tasks/lib/emr/emr-create-cluster.ts |
|---|
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_stepfunctions_tasks as stepfunctions_tasks } from 'aws-cdk-lib';
const scalingActionProperty: stepfunctions_tasks.EmrCreateCluster.ScalingActionProperty = {
simpleScalingPolicyConfiguration: {
scalingAdjustment: 123,
// the properties below are optional
adjustmentType: stepfunctions_tasks.EmrCreateCluster.ScalingAdjustmentType.CHANGE_IN_CAPACITY,
coolDown: 123,
},
// the properties below are optional
market: stepfunctions_tasks.EmrCreateCluster.InstanceMarket.ON_DEMAND,
};
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_stepfunctions_tasks as stepfunctions_tasks
scaling_action_property = stepfunctions_tasks.EmrCreateCluster.ScalingActionProperty(
simple_scaling_policy_configuration=stepfunctions_tasks.EmrCreateCluster.SimpleScalingPolicyConfigurationProperty(
scaling_adjustment=123,
# the properties below are optional
adjustment_type=stepfunctions_tasks.EmrCreateCluster.ScalingAdjustmentType.CHANGE_IN_CAPACITY,
cool_down=123
),
# the properties below are optional
market=stepfunctions_tasks.EmrCreateCluster.InstanceMarket.ON_DEMAND
)
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.stepfunctions.tasks.*;
ScalingActionProperty scalingActionProperty = ScalingActionProperty.builder()
.simpleScalingPolicyConfiguration(SimpleScalingPolicyConfigurationProperty.builder()
.scalingAdjustment(123)
// the properties below are optional
.adjustmentType(EmrCreateCluster.getScalingAdjustmentType().CHANGE_IN_CAPACITY)
.coolDown(123)
.build())
// the properties below are optional
.market(EmrCreateCluster.getInstanceMarket().ON_DEMAND)
.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.StepFunctions.Tasks;
var scalingActionProperty = new ScalingActionProperty {
SimpleScalingPolicyConfiguration = new SimpleScalingPolicyConfigurationProperty {
ScalingAdjustment = 123,
// the properties below are optional
AdjustmentType = EmrCreateCluster.ScalingAdjustmentType.CHANGE_IN_CAPACITY,
CoolDown = 123
},
// the properties below are optional
Market = EmrCreateCluster.InstanceMarket.ON_DEMAND
};
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"
scalingActionProperty := &ScalingActionProperty{
SimpleScalingPolicyConfiguration: &SimpleScalingPolicyConfigurationProperty{
ScalingAdjustment: jsii.Number(123),
// the properties below are optional
AdjustmentType: awscdk.Aws_stepfunctions_tasks.EmrCreateCluster.ScalingAdjustmentType_CHANGE_IN_CAPACITY,
CoolDown: jsii.Number(123),
},
// the properties below are optional
Market: awscdk.*Aws_stepfunctions_tasks.EmrCreateCluster.InstanceMarket_ON_DEMAND,
}
Properties
marketoptionalEmrCreateCluster.InstanceMarketmarketoptionalInstanceMarketmarketoptionalInstanceMarketMarketoptionalInstanceMarketMarketoptionalInstanceMarket #Not available for instance groups.
Default: EMR selected default
Instance groups use the market type specified for the group.
simpleScalingPolicyConfigurationEmrCreateCluster.simple_scaling_policy_configurationSimpleScalingPolicyConfigurationPropertysimpleScalingPolicyConfigurationSimpleScalingPolicyConfigurationPropertySimpleScalingPolicyConfigurationSimpleScalingPolicyConfigurationPropertySimpleScalingPolicyConfigurationSimpleScalingPolicyConfigurationProperty required #The type of adjustment the automatic scaling activity makes when triggered, and the periodicity of the adjustment.