Recommended approach to prevent failure with step function send task success failure due to expired token for asyn activity?

0

Hey Team, I have state machine with an asynchronous waiting activity which is responsible for generating new token every 24 hrs, we are using activity worker poller implementation of our state machine. Currently waiting steps in state machine wait for certain action perform in UI page after that action get completed it trigger SQS message via SNS which internally consume by our handler activity and then it read token of waiting activity and perform SendTaskSuccess Call.

Issue -> #1 Due to deployment in our service, it is possible that host become down which was handling waiting sfn activity request for updating token (every 24hrs) as an impact our token is not updated with latest token of waiting steps. Due to which we will have stale token for 24 hrs until retry happen for saving next token in waiting sfn activity. So if we call any sendTaskSuccess within that 24hr that will create taskTimeoutException due to stale token.

#2 Due to delay in saving new token, as our waiting activity internally send message to fifo queue which internally call ddb and save token, so there may be some delay in saving new token and if time of send task success from manual action completion trigger collapse with that then it again have same token expired exception.

No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions