Instances
The Management Console in K2 Workspace is superseded by the K2 Management Site and you should use the K2 Management Site to administer your K2 environment, rather than Management Console in K2 Workspace. (In certain cases you may need to use the Management Console in K2 Workspace to perform tasks that are not exposed in the K2 Management Site.)
The Instances node is used to administer active instances of the workflow, and to start new instances of the workflow manually.
Option | Description | Notes |
---|---|---|
Start | Start (Resume) an instance that is in the “Stopped” state. | You can only Start a process that is in the “Stopped” state. The Start/Stop functions are normally used to suspend execution for processes temporarily, for example to hold off execution until a problem has been resolved. Note that if any events like Escalations occur while the process is stopped, K2 will not execute those actions while the process is stooped, but will execute them immediately when the process is started if the escalation time was reached while the workflow was stopped. Stopped instances will not appear in users’ worklists. |
Stop | Stop (suspend) the selected instances if the workflow is in “Active” or “Running” status | You can only Stop process instances that are in the “Active” or “Running” state. “Active” means that the process is “alive” but waiting for something to happen. Usually this means that there is a client event that must be completed before the process can continue. “Running” means that K2 is busy executing code against the process. Processes should never be in “running” status for more than a few seconds (a few minutes is exceptional cases). If a process is constantly in the “running” status, it usually means that the workflow is in an endless loop and is negatively affecting the performance of the K2 server. |
Remove | Delete the process instance, with an option to delete the process history (reporting data) as well. | The “Remove Log Entries” option will delete all reporting data for the process instance if checked. If a process is deleted but the workflow reporting data is not deleted, the process may still appear in workflow reports with a “deleted” status. If the reporting data is deleted (Remove Log Entries is checked, in other words), the process will not appear in any reports at all. |
Go to Activity | Force an active process to go to a specific activity in the workflow. | This function is normally use to “skip” steps in the workflow or force the process to go back to a previous step. You can only redirect the process back to an activity in the same version of the process: if a newer version of the workflow has additional activities, they will not appear in this list. Note that K2 will execute all rules for the activity (e.g. destination rules, escalations etc.) again if the activity is restarted. |
Start New | Start a new instance of the workflow manually, optionally specifying the folio and entering values for any process-level datafields. | Normally used to start test instances of a workflow manually, or to start a process that performs some “polling” action. |
Select All/Clear All | Select (or clear selected) instances so that the same action can be applied to all selected instances. | Use this option to select multiple instances and perform the same action on all the instances simultaneously. |
Field | Description |
---|---|
Selected | Selects the Process Instance, allowing the Instance button options to be used. |
Process Full Name | Presents the full name of the Process Instance. |
Folio | This is a unique identifier that is used to identify each instance of a Process. |
Start Date | This is the date that an instance of the Workflow Process was started. |
Status | This is the status level of the Process instance e.g. completed, active or error |
Originator | The User who started the Process Instance. |
The following steps discusses how to start a new Process Instance:
- On the Instances screen, select the appropriate Process Instance and click the Start New button.
- On the Create new Process Instance screen, click the Load Data Fields button. This will load all the Data/XML Fields for the specified Process Instance.
Fields Description Sample Value Folio This is a unique identifier that is used to identify each instance of a Process. Enter a name for the Folio property OR select the Use Date option. Use Date Uses the current date and time as the Folio property. Click on the Use Date check box. Start Async Starts the Process Instance in Asynchronous mode, OR click on the check box to un-check it to start a Process Instance in Synchronous mode. Checked by default. Click on the check box to un-check it and start the Process in Synchronous mode. Load Data Fields Loads the Data Fields and XML Fields associated with the Process. Click Load Data Fields to load the Data/XML fields associated with the Process. Name Lists the name of the field. User Reference Value Allows an administrator to enter a data value for the Process Data Field. Enter the data value. Start Starts the new Process instance using the entered information. Click Start to start the new Process Instance. Cancel Exits the Start Process dialogue without starting a Process Instance. Click Cancel. - Click the Start button.
The following steps discusses how to use the Goto Activity feature.
- On the Instances screen, select the required Process Instance and click the Goto Activity button.
- On the Goto Activity screen, select the activity you wish to go to and click OK.
Option Description Sample Value Activity Name List the Activities available within the Process Instance. Select the Activity that the Process Instance is to be taken to and click on it.
Important Considerations about GoTo Activity
The following should be considered when using the Goto Activity in K2 Workspace Management Console:
- If the Goto activity action is performed, all active and running state activities and lines will expire and any further executions will cease before the process will go to the activity as specified.
- Data Field and XML Field values are not rolled back when going back to an activity that is prior to where the Data Fields or XML Fields have been set. If Line Rules are dependent on the Value of the Data Field or XML Field, the Rule might evaluate differently than expected.
- If any errors are received in the process , the entire process will be marked as in Error state, and all other executions will be stopped on all branches of the process. If you would like to perform a Goto Activity from error state, please consider the above points carefully. In some cases it would be better to perform an error retry or repair the error rather than to perform the Goto activity action.