Show / Hide Table of Contents

Class CreateAlarmOptions

Properties needed to make an alarm from a metric.

Inheritance
System.Object
CreateAlarmOptions
Implements
ICreateAlarmOptions
Namespace: Amazon.CDK.AWS.CloudWatch
Assembly: Amazon.CDK.AWS.CloudWatch.dll
Syntax (csharp)
public class CreateAlarmOptions : Object, ICreateAlarmOptions
Syntax (vb)
Public Class CreateAlarmOptions
    Inherits Object
    Implements ICreateAlarmOptions
Remarks

ExampleMetadata: infused

Examples
Function fn;


fn.MetricErrors().CreateAlarm(this, "Alarm", new CreateAlarmOptions {
    Threshold = 100,
    EvaluationPeriods = 2
});

Synopsis

Constructors

CreateAlarmOptions()

Properties

ActionsEnabled

Whether the actions for this alarm are enabled.

AlarmDescription

Description for the alarm.

AlarmName

Name of the alarm.

ComparisonOperator

Comparison to use to check if metric is breaching.

DatapointsToAlarm

The number of datapoints that must be breaching to trigger the alarm.

EvaluateLowSampleCountPercentile

Specifies whether to evaluate the data and potentially change the alarm state if there are too few data points to be statistically significant.

EvaluationPeriods

The number of periods over which data is compared to the specified threshold.

Period

(deprecated) The period over which the specified statistic is applied.

Statistic

(deprecated) What function to use for aggregating.

Threshold

The value against which the specified statistic is compared.

TreatMissingData

Sets how this alarm is to handle missing data points.

Constructors

CreateAlarmOptions()

public CreateAlarmOptions()

Properties

ActionsEnabled

Whether the actions for this alarm are enabled.

public Nullable<bool> ActionsEnabled { get; set; }
Property Value

System.Nullable<System.Boolean>

Remarks

Default: true

AlarmDescription

Description for the alarm.

public string AlarmDescription { get; set; }
Property Value

System.String

Remarks

Default: No description

AlarmName

Name of the alarm.

public string AlarmName { get; set; }
Property Value

System.String

Remarks

Default: Automatically generated name

ComparisonOperator

Comparison to use to check if metric is breaching.

public Nullable<ComparisonOperator> ComparisonOperator { get; set; }
Property Value

System.Nullable<ComparisonOperator>

Remarks

Default: GreaterThanOrEqualToThreshold

DatapointsToAlarm

The number of datapoints that must be breaching to trigger the alarm.

public Nullable<double> DatapointsToAlarm { get; set; }
Property Value

System.Nullable<System.Double>

Remarks

This is used only if you are setting an "M out of N" alarm. In that case, this value is the M. For more information, see Evaluating an Alarm in the Amazon CloudWatch User Guide.

Default: evaluationPeriods

See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html#alarm-evaluation

EvaluateLowSampleCountPercentile

Specifies whether to evaluate the data and potentially change the alarm state if there are too few data points to be statistically significant.

public string EvaluateLowSampleCountPercentile { get; set; }
Property Value

System.String

Remarks

Used only for alarms that are based on percentiles.

Default: - Not configured.

EvaluationPeriods

The number of periods over which data is compared to the specified threshold.

public double EvaluationPeriods { get; set; }
Property Value

System.Double

Period

(deprecated) The period over which the specified statistic is applied.

public Duration Period { get; set; }
Property Value

Duration

Remarks

Cannot be used with MathExpression objects.

Default: - The period from the metric

Stability: Deprecated

Statistic

(deprecated) What function to use for aggregating.

public string Statistic { get; set; }
Property Value

System.String

Remarks

Can be one of the following:

    Cannot be used with MathExpression objects.

    Default: - The statistic from the metric

    Stability: Deprecated

    Threshold

    The value against which the specified statistic is compared.

    public double Threshold { get; set; }
    Property Value

    System.Double

    TreatMissingData

    Sets how this alarm is to handle missing data points.

    public Nullable<TreatMissingData> TreatMissingData { get; set; }
    Property Value

    System.Nullable<TreatMissingData>

    Remarks

    Default: TreatMissingData.Missing

    Implements

    ICreateAlarmOptions
    Back to top Generated by DocFX