How To
Update a workflow
Understanding workflow continuity
Workflows are composed of multiple steps. When you modify workflow code, it’s important to consider how these changes might affect in-progress workflows.
Potential issues
If your code changes remove or modify existing steps, in-progress workflows may attempt to continue from a point that no longer exists. This can lead to workflow failures, typically resulting in the following error:
Safe changes
Modifying a workflow’s code is safe when:
- There are no active workflow runs
- You’re only adding new steps to the end of the workflow
Guidelines for updating workflows
Consider the following approaches when updating your workflow code:
- Accept potential failures: If you’re fine with in-progress workflows failing, you can make any code changes.
- Use a different route: To avoid failures, consider serving the updated workflow under a different route.
- Stop traffic before deployment: If you need to keep the same route, stop all traffic before deploying new code.
- Add steps only: If stopping traffic is not an option, limit your changes to adding new steps at the end of the workflow.
For a deeper understanding of these limitations, see our how workflows work section.
Was this page helpful?