-
Notifications
You must be signed in to change notification settings - Fork 729
Description
Currently, step functions can be written using the new functionality in AWS toolkit, which is quite helpful. One thing I do, is handle all deployment using serverless. For that, I parameterize my resources using the Fn::GetAtt instead of hardcoding the name of the lambda function in the JSON definition.
For example, the following state will be okay with serverless framework, but the rendering does not accept it:
"Downloader":{
"Type": "Task",
"Resource": {"Fn::GetAtt": ["download-handler", "Arn"]},
"Catch": [
{
"ErrorEquals": [
"Runtime.ExitError"
],
"Next": "RedefineParameters"
},
{
"ErrorEquals": [
"Task.Failed"
],
"Next": "HandleFailure"
}
],
"Retry": [ {
"ErrorEquals": ["Lambda.ServiceException", "Lambda.AWSLambdaException", "Lambda.SdkClientException", "Lambda.TooManyRequestsException"],
"IntervalSeconds": 5,
"MaxAttempts": 10,
"BackoffRate": 2
} ],
"ResultPath": "$.results",
"Next": "IsCommpleted"
}
Describe the solution you'd like
I would like this to not be flagged as a faulty JSON definition and the rendering to work
Describe alternatives you've considered
I have been manually removing all my parameterized resource names with empty "". But this can be tedious and error prone as your state machine grows in size
Additional context
Serverless will accept the JSON as write above, which is great. But the rendering of the state machine is not working which causes problems with dev speed