Search code examples
amazon-web-servicesamazon-swf

Do we require to change the workflow version of SWF if we add wait in workflow decider (using Flow framework)


We are using Flow framework to run our business workflow on SWF. Now, we want to change the order of parallel activities by introducing a 30 second wait time before running the first activity. This requires a change in our workflow worker. Now, since activities are still the same, do we need to bump up the workflow version for executing this change.

Flow documentation says that replay requires the code to be deterministic and any change in order would break the replay functionality. ref: https://docs.aws.amazon.com/amazonswf/latest/awsflowguide/java-flow-making-changes-decider-code.html

Now since these 2 activities are running in parallel earlier, and now in the code change we are trying to delay one of them by 30 seconds. Would the replay fail here if we don't upgrade the version ?


Solution

  • Yes, the replay is going to fail as it is not going to find a timer in the history of workflow that passed that point of execution with the old version of the code.