serverless-plugin-aws-alerts
serverless-plugin-aws-alerts copied to clipboard
Add support for step functions alarms
Feature Proposal
Serverless supports deploying AWS Step Functions, but this plugin does not seem to support adding CW alarms for Step Functions.
When I try to use this plugin to configure alarms for step functions, here's what I get:
serverless.yaml:
custom:
regionAlias: ${opt:regionAlias, 'uw1'}
alerts:
topics:
alarm:
topic: arn:aws:sns:#{AWS::Region}:#{AWS::AccountId}:alarm-topic-${self:provider.stage}
definitions:
executionsTimedOut:
namespace: 'AWS/States'
metric: ExecutionsTimedOut
threshold: 1
statistic: Sum
period: 3600
evaluationPeriods: 1
datapointsToAlarm: 1
comparisonOperator: GreaterThanOrEqualToThreshold
treatMissingData: missing
alarms:
- executionsTimedOut
stepFunctions:
stateMachines:
helloWorld:
alarms:
- executionsTimedOut
definition:
StartAt: SayHelloWorld
States:
SayHelloWorld:
Type: Pass
End: true
Error:
State machine [helloWorld] is malformed. Please check the README for more info. ValidationError: child "alarms" fails because ["alarms" must be an object]
For the ones that are looking for including alarms for step functions. The step function plugin already provides it built-in: https://www.serverless.com/plugins/serverless-step-functions#cloudwatch-alarms