Restarting Tasks
The Restart option is available for active, blocked and ended tasks.
Starting vs Restarting
There are three main differences between starting and restarting a task:
- Restarts use the real date and the logical date of the particular reference execution.
- The logical date affects calendar conditions. Since it is retrieved from the reference execution, the task checks the calendar conditions of the original execution.
- The real date has the effect that the task reacts as it is executed at the real date. It is also retrieved from the reference execution.
It is used for calculating the earliest start time of workflow tasks. The effect is that restarted workflows do not have waiting times because of the specified earliest start time, which has already been met when the original execution tookplace.
-
When restarting a task it is not necessary to execute the entire script again. You can specify a position within it from which reprocessing should start.
The restart point can be set in the script using the :RESTART statement. Thus, the processing steps that had ended successfully do not have to be repeated. Additionally, the :GENERATE script statement handles scripting blocks or individual script lines in restarts.
- Objects that are processed by an agent always run on the computer on which the original execution has been started. The relevant information is retrieved from the statistics and, therefore, it is irrelevant if the object has been modified or if agent groups are used.
Workflows: Agent group agents are newly retrieved if the top workflow is restarted. If you restart a child workflow, the agents are assumed from the statistics if the option Workflow tasks of the same Agent group should use the same agent is activated in the workflow Attributes.
Avoid repeating restarted tasks, as these are difficult to trace.
Restarting a task is possible from
- the Explorer in the Process Assembly perspective
- the Tasks table in the Process Monitoring perspective
- the Last Monitor also in the Process Monitoring perspective. This is available for workflows only.
To Restart a Task
-
Do one of the following:
- In the Process Monitoring perspective: Right-click the task and select Restart.
- In the Process Assembly perspective: Select the object, click the arrow on the Execute toolbar button to expand the options and select Restart. Alternatively, right-click the object on the Explorer and select Execute>Restart.
-
The Restart dialog is displayed, for example:
You can define the following execution settings:
Field Description Parameters Reference RunID You can indicate here the RunID of the execution that should be repeated. By default this field is populated with the RunID of either the highlighted task or the original execution.
If you need the original RunID later on, you can see it on the details of the task.
Restart Point This determines the point in the script from which the process will be restarted.
If you leave this field empty, the entire script will be reprocessed.
Keep start type Activate this checkbox if you want the task to keep its start type. For example, if a group has been assigned to the object, restarting will take place within the group. Wait for manual release Before being actually executed, tasks go through the following phases: Activation, Generation and Transfer. Activate this checkbox if you want the task to go through them but stop after transferring because you want to control when to execute it.
For details see Restarting Tasks.
To Release the Task Manually
There are several ways of releasing the task:
- For Workflows, from the Explorer in the Process Assembly perspective:
- Right-click the object and select Last Monitor. The task is opened in the Process Monitoring perspective in edit mode.
- Open the Modify... button on the upper left corner of the window and select Release manually.
Before releasing the task you can modify its parameters. These changes apply to the current execution only.
- For other executable objects, from the Tasks table in the Process Monitoring perspective.
- The task is already available in the list. Search for it as follows.
- Click the Filter button on the toolbar to toggle on the filter pane.
- Open the Status tab and expand the WAITING options.
- Activate Waiting for manual release.
- The task is displayed on the list. Right-click it and select Release manually.
- The task is already available in the list. Search for it as follows.
Queue You can assign a particular queue for this execution, which can be different to the one in the object's definition.
If you leave this field empty, the object queue is used.
Test Options Activate attributes dialog When you define an object type, you specify the general attributes that will always apply to objects with this type. In some cases, however, it might be necessary to change specific settings for a particular run of an object without modifying its general definitions.
If you activate this checkbox, before the task is executed a dialog pops up displaying the attributes that can be changed for this particular run. These values apply only to this execution.
Display in activation report
Activating option in this section causes the script to be processed and overrules the Generat at Runtime settings defined for the object in the General - Runtime page.
The activation report includes both the script statements and the content of all involved Include objects. In the case of jobs, also the job includes such as Header and Trailer.
Generated JCL Activate it to display the JCL in the report. After clicking the Execute button, the task is activated and the report opens. This allows you to check and, if necessary, modify it.
You can use this in combination with the Wait for manual release option. When you are happy with the results you can release the task for execution.
Original script Activate it to display the script in the report.
After clicking the Execute button, the task is activated and the report opens. This allows you to check and, if necessary, modify it.
You can use this in combination with the Wait for manual release option. When you are happy with the results you can release the task for execution.
Modifications of variables When testing your object definitions, you may want to modify your variables and check the results before actually executing them. Activate this option if you want those changes to be displayed in the activation report.
Modifications of attributes When testing your object definitions, you may want to modify their attributes and check the results before actually executing them. Activate this option if you want those changes to be displayed in the activation report. - For Workflows, from the Explorer in the Process Assembly perspective:
-
Click Restart.
-
If the Activate attributes dialog checkbox is activated, a dialog pops up where you can enter specific attribute settings for this run.
If any of the other test options is activated, a message opens prompting you to confirm that you want to execute the task after the script has been generated.
Easy Configuration and Automation or Restarts
Use the following script elements for this purpose:
Script elements | Description |
---|---|
Script element | Description |
This controls the processing of scripting lines during the execution of a script. |
|
This is used to set restart points in an executable object. |
|
Repeats the execution of a task. |
|
Retrieves whether the object has been activated in restart mode. |
|
SYS_ACT_RESTART_ME_NR |
Returns the run number (RunID) of an object that has been activated in restart mode. |
SYS_LAST_RESTART_POINT |
Supplies the name of the previous restart point in the script. |
SYS_LAST_RESTART_TEXT |
Supplies the text of the previous restart point as defined in the script. |
SYS_RESTART_POINT |
Supplies the restart point from which the object will be executed. |