Version Management in Openwhisk

In Openwhisk, version and version count are added, so whatever code has been written in the editor, the admin can have a copy of it and save it as a version.

The reason there is a version button in OpenWhisk is that code snippets are written to execute certain tasks. Suppose some changes are to be made to the code as per admin requirements. It is a very easy and convenient way. Those versions can be used later, if required.

  1. To create a version, the admin must click on the edit icon under the Action column on the Openwhisk page as shown in the following figure:
Figure 1. Figure 438 - Openwhisk Page
  1. The following page appears:
Figure 2. Figure 439 - Edit Action Page
  1. To add a new version, click on the Version in the Edit Action page.
Figure 3. Figure 440 - Version button
  1. The following page appears:
Figure 4. Figure 441 - List of Versions
  1. Provide the Version Name and click on the "Create New Version" button at the top right corner of the Version page.
Figure 5. Figure 442 - Provide name of version
  1. The following confirmation message appears:
Figure 6. Figure 443 - Confirmation message
  1. Click OK. The success message appears as shown in the following figure:
Figure 7. Figure 444 - Success message
  1. Click OK and the new version is created.
Figure 8. Figure 445 - New Version is added to the List of versions
  1. When a version is added to the list of versions, the version count is updated on edit page as shown in the following figure:
Figure 9. Figure 446 - Version Count
  1. Click on the publish icon as shown in the following figure:
Figure 10. Figure 447 - Publish Icon
  1. The following confirmation message appears. Click OK to continue.
Figure 11. Figure 448 - Confirmation Message
  1. On clicking the publish icon, it fetches the data from the saved thing and paste the code on the editor:
Figure 12. Figure 449 - Code editor
  1. If admin makes any changes to the code in the editor, he must save the code by clicking on the Save button.
Figure 13. Figure 450 - Save Button
  1. While creating a version, first code snippets must be saved, and then only a version can be created. In the case of failing to save the code, a failure message appears:
Figure 14. Figure 451 - Failure message
  • Version management is only applicable in the case of the editing an existing Openwhisk function and not in the case of adding a new Openwhisk function.
  • Clicking the publish button does not save the code it just copies and paste the code in the editor field. User must click save to make the code executable.