Skip to content

Commit

Permalink
PDFParseError: make alarm metric env and color specific
Browse files Browse the repository at this point in the history
  • Loading branch information
TomElliottFlexion committed Aug 16, 2024
1 parent cb3a59d commit f51de24
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ export const parseAndScrapePdfContents = async ({
view[i] = pdfBuffer[i];
}

// TODO: Wait to hear from Jessica on what should happen for PDF scraping failures
try {
return await applicationContext
.getUtilities()
Expand Down
4 changes: 2 additions & 2 deletions web-api/terraform/modules/api/alarms.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ resource "aws_cloudwatch_log_metric_filter" "pdf_parse_error_filter" {
pattern = "\"Failed to parse PDF\""

metric_transformation {
name = "PDFParseErrors"
name = "PDFParseErrors_${var.environment}_${var.current_color}"
namespace = "EFCMS"
value = "1"
}
Expand All @@ -22,4 +22,4 @@ resource "aws_cloudwatch_metric_alarm" "pdf_parse_error_alarm" {
threshold = "1"

alarm_actions = [var.alert_sns_topic_arn]
}
}

0 comments on commit f51de24

Please sign in to comment.