You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For a few services (Kinesis Data Streams, Elasticsearch, and Step Functions), Constructs automatically creates some CloudWatch alarms. However, even though they're available as properties, it's not possible to modify them:
// Deploy best practices CW Alarms for Kinesis Streamthis.cloudwatchAlarms=defaults.buildKinesisStreamCWAlarms(this);constsomeAlarm=this.cloudwatchAlarms[0];// I can get the metric configuration, but that doesn't allow me to change anything (such as thresholds)// This metricConfig object only contains metadata about the metric, such as which stat (avg, max, etc) was usedconstmetricConfig=someAlarm.metric.toMetricConfig();// Other than adding actions, there's not a lot I can do on the alarm itself eithersomeAlarm.addAlarmAction();
Use Case
Customers might have different requirements to the defaults used by Constructs (for example, they might want to be alerted when IteratorAge goes above 1 hour - instead of 12). They'd create this custom alarm on their CDK project, and would not want any duplication.
Proposed Solution
In all constructs that add alarms, add an option customers can set to false to disable their creation:
/** * Whether to create recommended CloudWatch alarms * * @default - Alarms are created */readonlycreateCloudWatchAlarms?: boolean
This is a 🚀 Feature Request
The text was updated successfully, but these errors were encountered:
For a few services (
Kinesis Data Streams
,Elasticsearch
, andStep Functions
), Constructs automatically creates some CloudWatch alarms. However, even though they're available as properties, it's not possible to modify them:Use Case
Customers might have different requirements to the defaults used by Constructs (for example, they might want to be alerted when
IteratorAge
goes above 1 hour - instead of 12). They'd create this custom alarm on their CDK project, and would not want any duplication.Proposed Solution
In all constructs that add alarms, add an option customers can set to
false
to disable their creation:This is a 🚀 Feature Request
The text was updated successfully, but these errors were encountered: