Objective

This article shows you how to revert the design back to one of the previously deployed versions of the workflow.

Before You Begin

In this scenario: 

You have a workflow that you deployed a few times and due to requirements changing or another issue, you want to revert the design back to one of the previously deployed versions.

It's also important to know how versioning works:

Image

In the above example, 3 is the latest deployed version and 1 is the minor version currently in saved state and not yet deployed. Should you deploy this current Designtime copy, the version will increase to 4.0.0.0

There will be 2 separate workflows in the category:

- Deployed version (Runtime ready Version)

- DesignTime version (Current design time copy containing the changes from last deployed version)

How-to Steps

In this article we have deployed the workflow and are currently on Version 3, but we want to revert the Runtime and Designtime version back to Version 1.

Steps to change runtime version

Refer to

https://help.k2.com/onlinehelp/k2five/userguide/5.0/default.htm#K2_Management_Site/Workflow_Server/Versions.htm?Highlight=versioning

1) Navigate to K2 Management > WorkFlow Server > Workflow > YOUR WORKFLOW

2) In Process Details open the Versions Tab and set Version 1 as Default:

Image

Image

Now all new instances will run against Version 1.

 

Steps to change Designtime Version

The following steps are a workaround that allows you to roll back the design time version of your workflow to a specific deployed version. Comprehensive version management features for all K2 artifacts are on the horizon to make this process much more seamless in the future.

1. Set the desired version as default. Refer to the first section above.

2. Delete all previous versions, up to the desired one you want to continue designing from. In this sample I deleted all except the Default:

Image

Image

3. Navigate to K2 Designer and note the designer version is still 3.0.0.1:

Image

4. Use the Delete button to delete the workflow:

Image

5. Note that the Workflow disappears from the tree and then re-populates with the only version available, Version 1. The icon also changes:

Image

6. Click on Edit and you will see version 1 of the workflow in designer to continue development.