AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.
Container for the parameters to the ExecutePolicy operation. Executes the specified policy. This can be useful for testing the design of your scaling policy.
Namespace: Amazon.AutoScaling.Model
Assembly: AWSSDK.AutoScaling.dll
Version: 3.x.y.z
public class ExecutePolicyRequest : AmazonAutoScalingRequest IAmazonWebServiceRequest
The ExecutePolicyRequest type exposes the following members
Name | Description | |
---|---|---|
ExecutePolicyRequest() |
Name | Type | Description | |
---|---|---|---|
AutoScalingGroupName | System.String |
Gets and sets the property AutoScalingGroupName. The name of the Auto Scaling group. |
|
BreachThreshold | System.Double |
Gets and sets the property BreachThreshold. The breach threshold for the alarm.
Required if the policy type is |
|
HonorCooldown | System.Boolean |
Gets and sets the property HonorCooldown. Indicates whether Amazon EC2 Auto Scaling waits for the cooldown period to complete before executing the policy.
Valid only if the policy type is |
|
MetricValue | System.Double |
Gets and sets the property MetricValue.
The metric value to compare to If you specify a metric value that doesn't correspond to a step adjustment for the policy, the call returns an error.
Required if the policy type is |
|
PolicyName | System.String |
Gets and sets the property PolicyName. The name or ARN of the policy. |
This example executes the specified policy.
var client = new AmazonAutoScalingClient(); var response = client.ExecutePolicy(new ExecutePolicyRequest { AutoScalingGroupName = "my-auto-scaling-group", BreachThreshold = 50, MetricValue = 59, PolicyName = "my-step-scale-out-policy" });
.NET Core App:
Supported in: 3.1
.NET Standard:
Supported in: 2.0
.NET Framework:
Supported in: 4.5, 4.0, 3.5