Skip to content

Commit

Permalink
Move this back into the condition
Browse files Browse the repository at this point in the history
  • Loading branch information
tjmw committed Jan 31, 2025
1 parent 459c190 commit 68f586e
Showing 1 changed file with 27 additions and 27 deletions.
54 changes: 27 additions & 27 deletions cdk/lib/frontend.ts
Original file line number Diff line number Diff line change
Expand Up @@ -354,33 +354,33 @@ export class Frontend extends GuStack {
treatMissingData: TreatMissingData.NOT_BREACHING,
snsTopicName: `alarms-handler-topic-${this.stage}`,
});
}

new GuAlarm(this, "ServerSideHighThresholdCreateFailureAlarm", {
app,
alarmName: alarmName(
"support-frontend create recurring product call failed multiple times for a known reason"
),
alarmDescription: alarmDescription(
"Someone pressed buy on a recurring product but received an error. This has happened multiple times for a known reason."
),
actionsEnabled: shouldCreateAlarms,
threshold: 1,
evaluationPeriods: 60,
datapointsToAlarm: 10,
comparisonOperator:
ComparisonOperator.GREATER_THAN_OR_EQUAL_TO_THRESHOLD,
metric: new Metric({
metricName: "ServerSideHighThresholdCreateFailure",
namespace: "support-frontend",
dimensionsMap: {
Stage: this.stage,
},
statistic: "Sum",
period: Duration.minutes(1),
}),
treatMissingData: TreatMissingData.NOT_BREACHING,
snsTopicName: `alarms-handler-topic-${this.stage}`,
});
new GuAlarm(this, "ServerSideHighThresholdCreateFailureAlarm", {
app,
alarmName: alarmName(
"support-frontend create recurring product call failed multiple times for a known reason"
),
alarmDescription: alarmDescription(
"Someone pressed buy on a recurring product but received an error. This has happened multiple times for a known reason."
),
actionsEnabled: shouldCreateAlarms,
threshold: 1,
evaluationPeriods: 60,
datapointsToAlarm: 10,
comparisonOperator:
ComparisonOperator.GREATER_THAN_OR_EQUAL_TO_THRESHOLD,
metric: new Metric({
metricName: "ServerSideHighThresholdCreateFailure",
namespace: "support-frontend",
dimensionsMap: {
Stage: this.stage,
},
statistic: "Sum",
period: Duration.minutes(1),
}),
treatMissingData: TreatMissingData.NOT_BREACHING,
snsTopicName: `alarms-handler-topic-${this.stage}`,
});
}
}
}

0 comments on commit 68f586e

Please sign in to comment.