interface ScalingRuleProperty
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.EMR.CfnInstanceGroupConfig.ScalingRuleProperty |
Java | software.amazon.awscdk.services.emr.CfnInstanceGroupConfig.ScalingRuleProperty |
Python | aws_cdk.aws_emr.CfnInstanceGroupConfig.ScalingRuleProperty |
TypeScript | @aws-cdk/aws-emr » CfnInstanceGroupConfig » ScalingRuleProperty |
ScalingRule
is a subproperty of the AutoScalingPolicy
property type.
ScalingRule
defines the scale-in or scale-out rules for scaling activity, including the CloudWatch metric alarm that triggers activity, how EC2 instances are added or removed, and the periodicity of adjustments. The automatic scaling policy for an instance group can comprise one or more automatic scaling rules.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as emr from '@aws-cdk/aws-emr';
const scalingRuleProperty: emr.CfnInstanceGroupConfig.ScalingRuleProperty = {
action: {
simpleScalingPolicyConfiguration: {
scalingAdjustment: 123,
// the properties below are optional
adjustmentType: 'adjustmentType',
coolDown: 123,
},
// the properties below are optional
market: 'market',
},
name: 'name',
trigger: {
cloudWatchAlarmDefinition: {
comparisonOperator: 'comparisonOperator',
metricName: 'metricName',
period: 123,
threshold: 123,
// the properties below are optional
dimensions: [{
key: 'key',
value: 'value',
}],
evaluationPeriods: 123,
namespace: 'namespace',
statistic: 'statistic',
unit: 'unit',
},
},
// the properties below are optional
description: 'description',
};
Properties
Name | Type | Description |
---|---|---|
action | IResolvable | Scaling | The conditions that trigger an automatic scaling activity. |
name | string | The name used to identify an automatic scaling rule. |
trigger | IResolvable | Scaling | The CloudWatch alarm definition that determines when automatic scaling activity is triggered. |
description? | string | A friendly, more verbose description of the automatic scaling rule. |
action
Type:
IResolvable
|
Scaling
The conditions that trigger an automatic scaling activity.
name
Type:
string
The name used to identify an automatic scaling rule.
Rule names must be unique within a scaling policy.
trigger
Type:
IResolvable
|
Scaling
The CloudWatch alarm definition that determines when automatic scaling activity is triggered.
description?
Type:
string
(optional)
A friendly, more verbose description of the automatic scaling rule.