Skip to content

Commit

Permalink
fix: CloudWatch alarms
Browse files Browse the repository at this point in the history
Make the alarms trigger for all `ERROR`, `Exception` and `WARNING` strings.
  • Loading branch information
patheard authored Jan 24, 2024
1 parent 8bdc5dd commit a450872
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions terraform/alarms.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
resource "aws_cloudwatch_log_metric_filter" "sre_bot_error" {
name = local.error_logged
pattern = "\"ERROR:slack_bolt.App\""
pattern = "?ERROR ?Exception"
log_group_name = local.api_cloudwatch_log_group

metric_transformation {
Expand Down Expand Up @@ -29,7 +29,7 @@ resource "aws_cloudwatch_metric_alarm" "sre_bot_error" {

resource "aws_cloudwatch_log_metric_filter" "sre_bot_warning" {
name = local.warning_logged
pattern = "\"WARNING:slack_bolt.App\""
pattern = "WARNING"
log_group_name = local.api_cloudwatch_log_group

metric_transformation {
Expand Down

0 comments on commit a450872

Please sign in to comment.