Class AlarmMuteRule
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.cloudwatch.AlarmMuteRule
- All Implemented Interfaces:
IAlarmMuteRuleRef,IEnvironmentAware,IResource,IAlarmMuteRule,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.138.0 (build 0ca7ee8)",
date="2026-08-10T14:50:59.307Z")
@Stability(Stable)
public class AlarmMuteRule
extends Resource
implements IAlarmMuteRule
A CloudWatch Alarm Mute Rule.
Example:
Alarm alarm1;
Alarm alarm2;
AlarmMuteRule alarmMuteRule = AlarmMuteRule.Builder.create(this, "AlarmMuteRule")
.alarms(List.of(alarm1))
// Defines the mute period begins at 0:00 everyday in UTC
.schedule(ScheduleExpression.cron(CronOptions.builder().minute("0").hour("0").build()))
// Specifies the mute rule lasts 1 hour.
.duration(Duration.hours(1))
.build();
// The mute target can be added after construction.
alarmMuteRule.addAlarm(alarm2);
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.services.cloudwatch.IAlarmMuteRule
IAlarmMuteRule.Jsii$Default, IAlarmMuteRule.Jsii$ProxyNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IResource
IResource.Jsii$Default -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAlarmMuteRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedAlarmMuteRule(software.amazon.jsii.JsiiObjectRef objRef) AlarmMuteRule(software.constructs.Construct scope, String id, AlarmMuteRuleProps props) -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a CloudWatch alarm to mute rule target alarms.static IAlarmMuteRulefromAlarmMuteRuleArn(software.constructs.Construct scope, String id, String alarmMuteRuleArn) Import an existing CloudWatch alarm mute rule provided an ARN.static IAlarmMuteRulefromAlarmMuteRuleName(software.constructs.Construct scope, String id, String alarmMuteRuleName) Import an existing CloudWatch alarm mute rule provided an Name.ARN of this alarm mute rule.Name of this alarm mute rule.A reference to a AlarmMuteRule resource.Methods inherited from class software.amazon.awscdk.Resource
applyCrossStackReferenceStrength, applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResource, withMethods inherited from class software.constructs.Construct
getNode, isConstruct, toStringMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNode, withMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.awscdk.IResource
applyRemovalPolicy, getStackMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
PROPERTY_INJECTION_ID
Uniquely identifies this class.
-
-
Constructor Details
-
AlarmMuteRule
protected AlarmMuteRule(software.amazon.jsii.JsiiObjectRef objRef) -
AlarmMuteRule
protected AlarmMuteRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
AlarmMuteRule
@Stability(Stable) public AlarmMuteRule(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull AlarmMuteRuleProps props) - Parameters:
scope- This parameter is required.id- This parameter is required.props- This parameter is required.
-
-
Method Details
-
fromAlarmMuteRuleArn
@Stability(Stable) @NotNull public static IAlarmMuteRule fromAlarmMuteRuleArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String alarmMuteRuleArn) Import an existing CloudWatch alarm mute rule provided an ARN.- Parameters:
scope- The parent creating construct (usuallythis). This parameter is required.id- The construct's name. This parameter is required.alarmMuteRuleArn- Alarm Mute Rule ARN. This parameter is required.
-
fromAlarmMuteRuleName
@Stability(Stable) @NotNull public static IAlarmMuteRule fromAlarmMuteRuleName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String alarmMuteRuleName) Import an existing CloudWatch alarm mute rule provided an Name.- Parameters:
scope- The parent creating construct (usuallythis). This parameter is required.id- The construct's name. This parameter is required.alarmMuteRuleName- Alarm Mute Rule Name. This parameter is required.
-
addAlarm
Add a CloudWatch alarm to mute rule target alarms.- Parameters:
alarm- This parameter is required.
-
getAlarmMuteRuleArn
ARN of this alarm mute rule.- Specified by:
getAlarmMuteRuleArnin interfaceIAlarmMuteRule
-
getAlarmMuteRuleName
Name of this alarm mute rule.- Specified by:
getAlarmMuteRuleNamein interfaceIAlarmMuteRule
-
getAlarmMuteRuleRef
A reference to a AlarmMuteRule resource.- Specified by:
getAlarmMuteRuleRefin interfaceIAlarmMuteRuleRef
-