Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Execution failed at task 'Emit - error timeout' in case of waiting timeout before customer submitting an order #15

Open
chong-aws opened this issue Sep 22, 2022 · 2 comments · May be fixed by #28

Comments

@chong-aws
Copy link

The error happens due to missing original input in 'Emit - Workflow Started TT' in case of timeout after 900s.
The issue can be simply fixed by configuring valid ResultPath e.g. '$.error' in 'Emit - Workflow Started TT' Error handling's catcher.

{
"error": "States.Runtime",
"cause": "An error occurred while executing the state 'Emit - error timeout' (entered at the event id #24). The JSONPath '$.detail.userId' specified for the field 'userId.$' could not be found in the input '{"Error":"States.Timeout","Cause":"","cause":"Customer timedout"}'"
}

@chong-aws
Copy link
Author

Refer to below link for where this issue located
https://workshop.serverlesscoffee.com/1b-workflow/6-waitfororder.html

@arthi-j
Copy link

arthi-j commented Nov 2, 2022

This can be fixed by updating the Error section for "Emit - Workflow Started TT" PutEvents task. In the catcher, the ResultPath needs to be set to something, for instance, $.cause. Else input will not be passed to output for timeout. Though output section is set to discard results and keep original input, this will only take effect for successful flow.

You can refer to "Emit - Awaiting Completion TT" that handles barista timeout. This does it correctly by setting ResultPath for catcher to $.comment.

guikcd added a commit to guikcd/serverless-coffee-workshop that referenced this issue Nov 22, 2022
@guikcd guikcd linked a pull request Nov 22, 2022 that will close this issue
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants