Refactor an existing workflow - will it break existing deployed and running processes?



You have an active process with many instances currently running. A request has been made to manipulate that process and then implement the changes that were made. These changes could be specific to the workflow, views, forms, SmartObjects.




Does K2 support versioning of the deployed workflows so that in-flight process instances are not affected by new rule changes? That is, only new instances after the deployment will use the newest version.




Yes K2 provides a distinction between the two versions of the workflow. When an instance of the workflow is started it will use the last version that was deployed to the K2 Server. Since we have running instances that started on an old version they will continue to run through the workflow based on the configuration at time of deployment. That means whatever version of forms and views that were available at the time of deployment are the version that will be run in that workflow. 


So more to our scenario, if we update the rules on a form for a client event and then check this form in say we are now on version 2. Version 1 of that form without the rule change was used in the inital deployment of that process. When new instances are started they will pull version 2 when they hit a client event. Old instances that are still running are told to find version 1 of that form/view when reaching this client event because that is what was available when the workflow was deployed.


Also, obviously making changes to the workflow and then deploying will cause all new instances to follow the new version of that workflow while old instances still follow the old design before say an event was added or removed.


Please note, this versioning does not apply to SmartObjects so do be warned. If you change the underlying data structure, add in new properties, etc. both the old and new instances are going to be effected by those changes. The older instances will definitely start seeing some errors.



0 Kudos
1 Reply

Re: Refactor an existing workflow - will it break existing deployed and running processes?

Also, forms and views are in the same boat as the smart objects. Only workflows are versioned in such as way that changes to newer versions don't impact older running instances.

0 Kudos