Skip to content

Commit

Permalink
fix(dependency issue): Add implicit dependency in api service between…
Browse files Browse the repository at this point in the history
… metric filters and log groups (#110)
  • Loading branch information
mdial89f authored Sep 1, 2023
1 parent e84490f commit e14bfd3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/services/api/serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ resources:
ApiGateway400ErrorCount:
Type: AWS::Logs::MetricFilter
Properties:
LogGroupName: !Sub /aws/api-gateway/${self:service}-${sls:stage}
LogGroupName: !Ref ApiGatewayLogGroup
FilterName: ApiGateway400ErrorCount
FilterPattern: '[ip, user, timestamp, request, status = 4*]'
MetricTransformations:
Expand All @@ -154,7 +154,7 @@ resources:
ApiGateway500ErrorCount:
Type: AWS::Logs::MetricFilter
Properties:
LogGroupName: !Sub /aws/api-gateway/${self:service}-${sls:stage}
LogGroupName: !Ref ApiGatewayLogGroup
FilterName: ApiGateway500ErrorCount
FilterPattern: '[ip, user, timestamp, request, status = 5*]'
MetricTransformations:
Expand Down Expand Up @@ -199,7 +199,7 @@ resources:
LambdaLogMessageMetricFilter:
Type: "AWS::Logs::MetricFilter"
Properties:
LogGroupName: /aws/lambda/${self:service}-${sls:stage}-search
LogGroupName: !Ref SearchLogGroup
FilterPattern: "ERROR"
MetricTransformations:
- MetricName: LambdaErrorCount
Expand Down

0 comments on commit e14bfd3

Please sign in to comment.