@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class PutCompositeAlarmRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
NOOP
Constructor and Description |
---|
PutCompositeAlarmRequest() |
Modifier and Type | Method and Description |
---|---|
PutCompositeAlarmRequest |
clone()
Creates a shallow clone of this object for all fields except the handler context.
|
boolean |
equals(Object obj) |
Boolean |
getActionsEnabled()
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
|
String |
getActionsSuppressor()
Actions will be suppressed if the suppressor alarm is in the
ALARM state. |
Integer |
getActionsSuppressorExtensionPeriod()
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM state. |
Integer |
getActionsSuppressorWaitPeriod()
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM state. |
List<String> |
getAlarmActions()
The actions to execute when this alarm transitions to the
ALARM state from any other state. |
String |
getAlarmDescription()
The description for the composite alarm.
|
String |
getAlarmName()
The name for the composite alarm.
|
String |
getAlarmRule()
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state.
|
List<String> |
getInsufficientDataActions()
The actions to execute when this alarm transitions to the
INSUFFICIENT_DATA state from any other
state. |
List<String> |
getOKActions()
The actions to execute when this alarm transitions to an
OK state from any other state. |
List<Tag> |
getTags()
A list of key-value pairs to associate with the alarm.
|
int |
hashCode() |
Boolean |
isActionsEnabled()
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
|
void |
setActionsEnabled(Boolean actionsEnabled)
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
|
void |
setActionsSuppressor(String actionsSuppressor)
Actions will be suppressed if the suppressor alarm is in the
ALARM state. |
void |
setActionsSuppressorExtensionPeriod(Integer actionsSuppressorExtensionPeriod)
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM state. |
void |
setActionsSuppressorWaitPeriod(Integer actionsSuppressorWaitPeriod)
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM state. |
void |
setAlarmActions(Collection<String> alarmActions)
The actions to execute when this alarm transitions to the
ALARM state from any other state. |
void |
setAlarmDescription(String alarmDescription)
The description for the composite alarm.
|
void |
setAlarmName(String alarmName)
The name for the composite alarm.
|
void |
setAlarmRule(String alarmRule)
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state.
|
void |
setInsufficientDataActions(Collection<String> insufficientDataActions)
The actions to execute when this alarm transitions to the
INSUFFICIENT_DATA state from any other
state. |
void |
setOKActions(Collection<String> oKActions)
The actions to execute when this alarm transitions to an
OK state from any other state. |
void |
setTags(Collection<Tag> tags)
A list of key-value pairs to associate with the alarm.
|
String |
toString()
Returns a string representation of this object.
|
PutCompositeAlarmRequest |
withActionsEnabled(Boolean actionsEnabled)
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
|
PutCompositeAlarmRequest |
withActionsSuppressor(String actionsSuppressor)
Actions will be suppressed if the suppressor alarm is in the
ALARM state. |
PutCompositeAlarmRequest |
withActionsSuppressorExtensionPeriod(Integer actionsSuppressorExtensionPeriod)
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM state. |
PutCompositeAlarmRequest |
withActionsSuppressorWaitPeriod(Integer actionsSuppressorWaitPeriod)
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM state. |
PutCompositeAlarmRequest |
withAlarmActions(Collection<String> alarmActions)
The actions to execute when this alarm transitions to the
ALARM state from any other state. |
PutCompositeAlarmRequest |
withAlarmActions(String... alarmActions)
The actions to execute when this alarm transitions to the
ALARM state from any other state. |
PutCompositeAlarmRequest |
withAlarmDescription(String alarmDescription)
The description for the composite alarm.
|
PutCompositeAlarmRequest |
withAlarmName(String alarmName)
The name for the composite alarm.
|
PutCompositeAlarmRequest |
withAlarmRule(String alarmRule)
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state.
|
PutCompositeAlarmRequest |
withInsufficientDataActions(Collection<String> insufficientDataActions)
The actions to execute when this alarm transitions to the
INSUFFICIENT_DATA state from any other
state. |
PutCompositeAlarmRequest |
withInsufficientDataActions(String... insufficientDataActions)
The actions to execute when this alarm transitions to the
INSUFFICIENT_DATA state from any other
state. |
PutCompositeAlarmRequest |
withOKActions(Collection<String> oKActions)
The actions to execute when this alarm transitions to an
OK state from any other state. |
PutCompositeAlarmRequest |
withOKActions(String... oKActions)
The actions to execute when this alarm transitions to an
OK state from any other state. |
PutCompositeAlarmRequest |
withTags(Collection<Tag> tags)
A list of key-value pairs to associate with the alarm.
|
PutCompositeAlarmRequest |
withTags(Tag... tags)
A list of key-value pairs to associate with the alarm.
|
addHandlerContext, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getHandlerContext, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestCredentialsProvider, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public void setActionsEnabled(Boolean actionsEnabled)
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm. The
default is TRUE
.
actionsEnabled
- Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
The default is TRUE
.public Boolean getActionsEnabled()
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm. The
default is TRUE
.
TRUE
.public PutCompositeAlarmRequest withActionsEnabled(Boolean actionsEnabled)
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm. The
default is TRUE
.
actionsEnabled
- Indicates whether actions should be executed during any changes to the alarm state of the composite alarm.
The default is TRUE
.public Boolean isActionsEnabled()
Indicates whether actions should be executed during any changes to the alarm state of the composite alarm. The
default is TRUE
.
TRUE
.public List<String> getAlarmActions()
The actions to execute when this alarm transitions to the ALARM
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
ALARM
state from any other state.
Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
public void setAlarmActions(Collection<String> alarmActions)
The actions to execute when this alarm transitions to the ALARM
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
alarmActions
- The actions to execute when this alarm transitions to the ALARM
state from any other state.
Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
public PutCompositeAlarmRequest withAlarmActions(String... alarmActions)
The actions to execute when this alarm transitions to the ALARM
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
NOTE: This method appends the values to the existing list (if any). Use
setAlarmActions(java.util.Collection)
or withAlarmActions(java.util.Collection)
if you want to
override the existing values.
alarmActions
- The actions to execute when this alarm transitions to the ALARM
state from any other state.
Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
public PutCompositeAlarmRequest withAlarmActions(Collection<String> alarmActions)
The actions to execute when this alarm transitions to the ALARM
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
alarmActions
- The actions to execute when this alarm transitions to the ALARM
state from any other state.
Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
Systems Manager actions:
arn:aws:ssm:region:account-id:opsitem:severity
public void setAlarmDescription(String alarmDescription)
The description for the composite alarm.
alarmDescription
- The description for the composite alarm.public String getAlarmDescription()
The description for the composite alarm.
public PutCompositeAlarmRequest withAlarmDescription(String alarmDescription)
The description for the composite alarm.
alarmDescription
- The description for the composite alarm.public void setAlarmName(String alarmName)
The name for the composite alarm. This name must be unique within the Region.
alarmName
- The name for the composite alarm. This name must be unique within the Region.public String getAlarmName()
The name for the composite alarm. This name must be unique within the Region.
public PutCompositeAlarmRequest withAlarmName(String alarmName)
The name for the composite alarm. This name must be unique within the Region.
alarmName
- The name for the composite alarm. This name must be unique within the Region.public void setAlarmRule(String alarmRule)
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state. For each alarm that you reference, you designate a function that specifies whether that alarm needs to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to combine multiple functions in a single expression. You can use parenthesis to logically group the functions in your expression.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your alarm
actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite alarm goes
into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm goes to
ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM state. This
example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes into
ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if NetworkOutTooHigh is in OK
state. This provides another example of using a composite alarm to prevent noise. This rule ensures that you are
not notified with an alarm action on high CPU or disk usage if a known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression
can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and parentheses.
alarmRule
- An expression that specifies which other alarms are to be evaluated to determine this composite alarm's
state. For each alarm that you reference, you designate a function that specifies whether that alarm needs
to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to
combine multiple functions in a single expression. You can use parenthesis to logically group the
functions in your expression.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your
alarm actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have
to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite alarm
goes into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm
goes to ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM
state. This example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes
into ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if
NetworkOutTooHigh is in OK state. This provides another example of using a composite alarm to prevent
noise. This rule ensures that you are not notified with an alarm action on high CPU or disk usage if a
known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and
parentheses.
public String getAlarmRule()
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state. For each alarm that you reference, you designate a function that specifies whether that alarm needs to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to combine multiple functions in a single expression. You can use parenthesis to logically group the functions in your expression.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your alarm
actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite alarm goes
into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm goes to
ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM state. This
example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes into
ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if NetworkOutTooHigh is in OK
state. This provides another example of using a composite alarm to prevent noise. This rule ensures that you are
not notified with an alarm action on high CPU or disk usage if a known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression
can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and parentheses.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your
alarm actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have
to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite
alarm goes into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM
state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm
goes to ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM
state. This example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes
into ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if
NetworkOutTooHigh is in OK state. This provides another example of using a composite alarm to prevent
noise. This rule ensures that you are not notified with an alarm action on high CPU or disk usage if a
known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and
parentheses.
public PutCompositeAlarmRequest withAlarmRule(String alarmRule)
An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state. For each alarm that you reference, you designate a function that specifies whether that alarm needs to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to combine multiple functions in a single expression. You can use parenthesis to logically group the functions in your expression.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your alarm
actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite alarm goes
into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm goes to
ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM state. This
example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes into
ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if NetworkOutTooHigh is in OK
state. This provides another example of using a composite alarm to prevent noise. This rule ensures that you are
not notified with an alarm action on high CPU or disk usage if a known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression
can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and parentheses.
alarmRule
- An expression that specifies which other alarms are to be evaluated to determine this composite alarm's
state. For each alarm that you reference, you designate a function that specifies whether that alarm needs
to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to
combine multiple functions in a single expression. You can use parenthesis to logically group the
functions in your expression.
You can use either alarm names or ARNs to reference the other alarms that are to be evaluated.
Functions can include the following:
ALARM("alarm-name or alarm-ARN")
is TRUE if the named alarm is in ALARM state.
OK("alarm-name or alarm-ARN")
is TRUE if the named alarm is in OK state.
INSUFFICIENT_DATA("alarm-name or alarm-ARN")
is TRUE if the named alarm is in
INSUFFICIENT_DATA state.
TRUE
always evaluates to TRUE.
FALSE
always evaluates to FALSE.
TRUE and FALSE are useful for testing a complex AlarmRule
structure, and for testing your
alarm actions.
Alarm names specified in AlarmRule
can be surrounded with double-quotes ("), but do not have
to be.
The following are some examples of AlarmRule
:
ALARM(CPUUtilizationTooHigh) AND ALARM(DiskReadOpsTooHigh)
specifies that the composite alarm
goes into ALARM state only if both CPUUtilizationTooHigh and DiskReadOpsTooHigh alarms are in ALARM state.
ALARM(CPUUtilizationTooHigh) AND NOT ALARM(DeploymentInProgress)
specifies that the alarm
goes to ALARM state if CPUUtilizationTooHigh is in ALARM state and DeploymentInProgress is not in ALARM
state. This example reduces alarm noise during a known deployment window.
(ALARM(CPUUtilizationTooHigh) OR ALARM(DiskReadOpsTooHigh)) AND OK(NetworkOutTooHigh)
goes
into ALARM state if CPUUtilizationTooHigh OR DiskReadOpsTooHigh is in ALARM state, and if
NetworkOutTooHigh is in OK state. This provides another example of using a composite alarm to prevent
noise. This rule ensures that you are not notified with an alarm action on high CPU or disk usage if a
known network problem is also occurring.
The AlarmRule
can specify as many as 100 "children" alarms. The AlarmRule
expression can have as many as 500 elements. Elements are child alarms, TRUE or FALSE statements, and
parentheses.
public List<String> getInsufficientDataActions()
The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any other
state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
INSUFFICIENT_DATA
state from any
other state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public void setInsufficientDataActions(Collection<String> insufficientDataActions)
The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any other
state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
insufficientDataActions
- The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any
other state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public PutCompositeAlarmRequest withInsufficientDataActions(String... insufficientDataActions)
The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any other
state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
NOTE: This method appends the values to the existing list (if any). Use
setInsufficientDataActions(java.util.Collection)
or
withInsufficientDataActions(java.util.Collection)
if you want to override the existing values.
insufficientDataActions
- The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any
other state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public PutCompositeAlarmRequest withInsufficientDataActions(Collection<String> insufficientDataActions)
The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any other
state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
insufficientDataActions
- The actions to execute when this alarm transitions to the INSUFFICIENT_DATA
state from any
other state. Each action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public List<String> getOKActions()
The actions to execute when this alarm transitions to an OK
state from any other state. Each action
is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
OK
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public void setOKActions(Collection<String> oKActions)
The actions to execute when this alarm transitions to an OK
state from any other state. Each action
is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
oKActions
- The actions to execute when this alarm transitions to an OK
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public PutCompositeAlarmRequest withOKActions(String... oKActions)
The actions to execute when this alarm transitions to an OK
state from any other state. Each action
is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
NOTE: This method appends the values to the existing list (if any). Use
setOKActions(java.util.Collection)
or withOKActions(java.util.Collection)
if you want to
override the existing values.
oKActions
- The actions to execute when this alarm transitions to an OK
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public PutCompositeAlarmRequest withOKActions(Collection<String> oKActions)
The actions to execute when this alarm transitions to an OK
state from any other state. Each action
is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
oKActions
- The actions to execute when this alarm transitions to an OK
state from any other state. Each
action is specified as an Amazon Resource Name (ARN).
Valid Values: ]
Amazon SNS actions:
arn:aws:sns:region:account-id:sns-topic-name
Lambda actions:
Invoke the latest version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name
Invoke a specific version of a Lambda function:
arn:aws:lambda:region:account-id:function:function-name:version-number
Invoke a function by using an alias Lambda function:
arn:aws:lambda:region:account-id:function:function-name:alias-name
public List<Tag> getTags()
A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm. To be
able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
public void setTags(Collection<Tag> tags)
A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm. To be
able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
tags
- A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm.
To be able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
public PutCompositeAlarmRequest withTags(Tag... tags)
A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm. To be
able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
NOTE: This method appends the values to the existing list (if any). Use
setTags(java.util.Collection)
or withTags(java.util.Collection)
if you want to override the
existing values.
tags
- A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm.
To be able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
public PutCompositeAlarmRequest withTags(Collection<Tag> tags)
A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm. To be
able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
tags
- A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm.
To be able to associate tags with the alarm when you create the alarm, you must have the
cloudwatch:TagResource
permission.
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
If you are using this operation to update an existing alarm, any tags you specify in this parameter are ignored. To change the tags of an existing alarm, use TagResource or UntagResource.
public void setActionsSuppressor(String actionsSuppressor)
Actions will be suppressed if the suppressor alarm is in the ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing alarm.
actionsSuppressor
- Actions will be suppressed if the suppressor alarm is in the ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing
alarm.public String getActionsSuppressor()
Actions will be suppressed if the suppressor alarm is in the ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing alarm.
ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing
alarm.public PutCompositeAlarmRequest withActionsSuppressor(String actionsSuppressor)
Actions will be suppressed if the suppressor alarm is in the ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing alarm.
actionsSuppressor
- Actions will be suppressed if the suppressor alarm is in the ALARM
state.
ActionsSuppressor
can be an AlarmName or an Amazon Resource Name (ARN) from an existing
alarm.public void setActionsSuppressorWaitPeriod(Integer actionsSuppressorWaitPeriod)
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
actionsSuppressorWaitPeriod
- The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
public Integer getActionsSuppressorWaitPeriod()
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
public PutCompositeAlarmRequest withActionsSuppressorWaitPeriod(Integer actionsSuppressorWaitPeriod)
The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
actionsSuppressorWaitPeriod
- The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the
ALARM
state. After this time, the composite alarm performs its actions.
WaitPeriod
is required only when ActionsSuppressor
is specified.
public void setActionsSuppressorExtensionPeriod(Integer actionsSuppressorExtensionPeriod)
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
actionsSuppressorExtensionPeriod
- The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
public Integer getActionsSuppressorExtensionPeriod()
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
public PutCompositeAlarmRequest withActionsSuppressorExtensionPeriod(Integer actionsSuppressorExtensionPeriod)
The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
actionsSuppressorExtensionPeriod
- The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the
ALARM
state. After this time, the composite alarm performs its actions.
ExtensionPeriod
is required only when ActionsSuppressor
is specified.
public String toString()
toString
in class Object
Object.toString()
public PutCompositeAlarmRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()