Class GroupMetric
Group metrics that an Auto Scaling group sends to Amazon CloudWatch.
Inheritance
Namespace: Amazon.CDK.AWS.AutoScaling
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class GroupMetric : DeputyBase
Syntax (vb)
Public Class GroupMetric
Inherits DeputyBase
Remarks
ExampleMetadata: infused
Examples
Vpc vpc;
InstanceType instanceType;
IMachineImage machineImage;
// Enable monitoring of all group metrics
// Enable monitoring of all group metrics
new AutoScalingGroup(this, "ASG", new AutoScalingGroupProps {
Vpc = vpc,
InstanceType = instanceType,
MachineImage = machineImage,
// ...
GroupMetrics = new [] { GroupMetrics.All() }
});
// Enable monitoring for a subset of group metrics
// Enable monitoring for a subset of group metrics
new AutoScalingGroup(this, "ASG", new AutoScalingGroupProps {
Vpc = vpc,
InstanceType = instanceType,
MachineImage = machineImage,
// ...
GroupMetrics = new [] { new GroupMetrics(GroupMetric.MIN_SIZE, GroupMetric.MAX_SIZE) }
});
Synopsis
Constructors
GroupMetric(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
GroupMetric(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
GroupMetric(String) |
Properties
DESIRED_CAPACITY | The number of instances that the Auto Scaling group attempts to maintain. |
IN_SERVICE_INSTANCES | The number of instances that are running as part of the Auto Scaling group This metric does not include instances that are pending or terminating. |
MAX_SIZE | The maximum size of the Auto Scaling group. |
MIN_SIZE | The minimum size of the Auto Scaling group. |
Name | The name of the group metric. |
PENDING_INSTANCES | The number of instances that are pending A pending instance is not yet in service, this metric does not include instances that are in service or terminating. |
STANDBY_INSTANCES | The number of instances that are in a Standby state Instances in this state are still running but are not actively in service. |
TERMINATING_INSTANCES | The number of instances that are in the process of terminating This metric does not include instances that are in service or pending. |
TOTAL_INSTANCES | The total number of instances in the Auto Scaling group This metric identifies the number of instances that are in service, pending, and terminating. |
Constructors
GroupMetric(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected GroupMetric(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
GroupMetric(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected GroupMetric(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
GroupMetric(String)
public GroupMetric(string name)
Parameters
- name System.String
Properties
DESIRED_CAPACITY
The number of instances that the Auto Scaling group attempts to maintain.
public static GroupMetric DESIRED_CAPACITY { get; }
Property Value
IN_SERVICE_INSTANCES
The number of instances that are running as part of the Auto Scaling group This metric does not include instances that are pending or terminating.
public static GroupMetric IN_SERVICE_INSTANCES { get; }
Property Value
MAX_SIZE
The maximum size of the Auto Scaling group.
public static GroupMetric MAX_SIZE { get; }
Property Value
MIN_SIZE
The minimum size of the Auto Scaling group.
public static GroupMetric MIN_SIZE { get; }
Property Value
Name
The name of the group metric.
public virtual string Name { get; }
Property Value
System.String
PENDING_INSTANCES
The number of instances that are pending A pending instance is not yet in service, this metric does not include instances that are in service or terminating.
public static GroupMetric PENDING_INSTANCES { get; }
Property Value
STANDBY_INSTANCES
The number of instances that are in a Standby state Instances in this state are still running but are not actively in service.
public static GroupMetric STANDBY_INSTANCES { get; }
Property Value
TERMINATING_INSTANCES
The number of instances that are in the process of terminating This metric does not include instances that are in service or pending.
public static GroupMetric TERMINATING_INSTANCES { get; }
Property Value
TOTAL_INSTANCES
The total number of instances in the Auto Scaling group This metric identifies the number of instances that are in service, pending, and terminating.
public static GroupMetric TOTAL_INSTANCES { get; }
Property Value