| Modifier and Type | Method and Description |
|---|---|
CfnAlarm.Builder |
alarmName(String alarmName)
The name of the alarm.
|
CfnAlarm |
build() |
CfnAlarm.Builder |
comparisonOperator(String comparisonOperator)
The arithmetic operation to use when comparing the specified statistic and threshold.
|
CfnAlarm.Builder |
contactProtocols(List<String> contactProtocols)
The contact protocols for the alarm, such as `Email` , `SMS` (text messaging), or both.
|
static CfnAlarm.Builder |
create(software.constructs.Construct scope,
String id) |
CfnAlarm.Builder |
datapointsToAlarm(Number datapointsToAlarm)
The number of data points within the evaluation periods that must be breaching to cause the alarm to go to the `ALARM` state.
|
CfnAlarm.Builder |
evaluationPeriods(Number evaluationPeriods)
The number of periods over which data is compared to the specified threshold.
|
CfnAlarm.Builder |
metricName(String metricName)
The name of the metric associated with the alarm.
|
CfnAlarm.Builder |
monitoredResourceName(String monitoredResourceName)
The name of the Lightsail resource that the alarm monitors.
|
CfnAlarm.Builder |
notificationEnabled(Boolean notificationEnabled)
A Boolean value indicating whether the alarm is enabled.
|
CfnAlarm.Builder |
notificationEnabled(IResolvable notificationEnabled)
A Boolean value indicating whether the alarm is enabled.
|
CfnAlarm.Builder |
notificationTriggers(List<String> notificationTriggers)
The alarm states that trigger a notification.
|
CfnAlarm.Builder |
threshold(Number threshold)
The value against which the specified statistic is compared.
|
CfnAlarm.Builder |
treatMissingData(String treatMissingData)
Specifies how the alarm handles missing data points.
|
@Stability(value=Stable) public static CfnAlarm.Builder create(software.constructs.Construct scope, String id)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.CfnAlarm.Builder.@Stability(value=Stable) public CfnAlarm.Builder alarmName(String alarmName)
alarmName - The name of the alarm. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder comparisonOperator(String comparisonOperator)
comparisonOperator - The arithmetic operation to use when comparing the specified statistic and threshold. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder evaluationPeriods(Number evaluationPeriods)
evaluationPeriods - The number of periods over which data is compared to the specified threshold. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder metricName(String metricName)
metricName - The name of the metric associated with the alarm. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder monitoredResourceName(String monitoredResourceName)
monitoredResourceName - The name of the Lightsail resource that the alarm monitors. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder threshold(Number threshold)
threshold - The value against which the specified statistic is compared. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder contactProtocols(List<String> contactProtocols)
Allowed Values : Email | SMS
contactProtocols - The contact protocols for the alarm, such as `Email` , `SMS` (text messaging), or both. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder datapointsToAlarm(Number datapointsToAlarm)
datapointsToAlarm - The number of data points within the evaluation periods that must be breaching to cause the alarm to go to the `ALARM` state. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder notificationEnabled(Boolean notificationEnabled)
notificationEnabled - A Boolean value indicating whether the alarm is enabled. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder notificationEnabled(IResolvable notificationEnabled)
notificationEnabled - A Boolean value indicating whether the alarm is enabled. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder notificationTriggers(List<String> notificationTriggers)
To specify the
OKandINSUFFICIENT_DATAvalues, you must also specifyContactProtocolsvalues. Otherwise, theOKandINSUFFICIENT_DATAvalues will not take effect and the stack will drift.
Allowed Values : OK | ALARM | INSUFFICIENT_DATA
notificationTriggers - The alarm states that trigger a notification. This parameter is required.this@Stability(value=Stable) public CfnAlarm.Builder treatMissingData(String treatMissingData)
An alarm can treat missing data in the following ways:
breaching - Assumes the missing data is not within the threshold. Missing data counts towards the number of times that the metric is not within the threshold.notBreaching - Assumes the missing data is within the threshold. Missing data does not count towards the number of times that the metric is not within the threshold.ignore - Ignores the missing data. Maintains the current alarm state.missing - Missing data is treated as missing.treatMissingData - Specifies how the alarm handles missing data points. This parameter is required.thisCopyright © 2022. All rights reserved.