Activating/Executing Schedule Objects
After you have defined the Schedule object, you must execute it manually for the first time to activate it. From that moment onward, the Schedule is in Active status and it runs automatically. This means that it automatically starts the tasks according to the settings that you have defined (the Schedule's Period Turnaround Time and Period Duration as well as the Start Time, Offset times and Calendar Condition of each task, and so on).
You can activate a Schedule as follows:
- On the Explorer list, right-click the Schedule and select Execute > Execute. Alternatively click the Execute button on the toolbar.
- On the Schedule object definition pages, click the Execute button on the toolbar.
When the Schedule is activated/executed, it checks the start times of all its tasks. There are two possibilities:
-
The start time of a task is in the future
The status of the task is set to Waiting for start time. When the Scheduled time arrives, the task is initiated.
-
The start time of a task lies in the past
The status of the task is set to ENDED_TIMEOUT -Start time exceeded. You have to reset it; as a result, it executes immediately.
When tasks start, all conditions and dependencies (Calendars, Sync objects, and so on) are checked. The tasks start or do not start depending on the results of these checks and the status of the tasks is set accordingly.
During their execution, the runtime of the tasks in the Schedule is monitored. This information allows you to react as needed if the runtimes are not what you expect. For more information, see Monitoring Schedules. You can also see the Schedule and its tasks on the Tasks list in the Process Monitoring perspective. For more information, see Understanding the Task List.
This page includes the following:
What Happens when the Tasks Are Activated?
When the start time of a task arrives, the Schedule object performs several checks. These checks determine when it should be executed and whether follow-up objects must be executed depending on its end status. This list describes the possible scenarios:
-
Are there dependencies between the Schedule period and the task start time?
-
Yes
-
Scenario 1: The task start time is before the Schedule period turnaround time.
Task status: ENDED_TIMEOUT - Start time exceeded
The task is not started. The system tries to start it again when the current period turnaround has elapsed and the new period starts.
-
Scenario 2: The task start time is later than the schedule period turnaround time.
Task status: WAITING - Waiting for start time
The task is not started. It is executed when its start time arrives.
-
-
No
Task status: WAITING - Waiting for start time
Next checks are performed.
-
-
Are there calendar conditions to be considered?
-
Yes
Calendar settings are applied and, if necessary, the task is not executed.
-
No
Task status: WAITING - Waiting for start time
Next checks are performed.
-
-
Are Sync objects assigned to the Schedule?
-
Yes
The conditions are evaluated and, if necessary, the task is not executed.
-
No
The task is executed.
-
-
Are follow-up tasks assigned to the task?
-
Yes
-
Scenario 1: Follow-up tasks are started and processing ends. The task has the OK status as specified in the task properties.
-
Scenario 2: The task does not have the OK status that is specified in its properties.
The system reacts automatically and either starts the task again or executes a different one, according to its property definitions.
-
-
No
The process starts again with the next period turnaround.
-
The following graphic depicts how the system checks scheduled tasks:
Special Case: A Task Is Still Running After the Period Turnaround
Schedules trigger the execution of tasks once a day according to the conditions that you have defined. With each period turnaround, the Schedule starts anew and both the Schedule and its tasks get a new RunID.
You probably define the task start times in a way that they do not collide with period turnarounds. However, if that happens, this is how the tasks and the Schedule behave:
-
The task continues its execution. The instance of the Schedule that started the task has no longer control over it; for example, any result checks on the task will not be evaluated or executed when the task ends.
- The instance of the Schedule that started the task ends as usual. The tasks in the Schedule start again with the next period turnaround.
- If you set the flat list view in the list of Tasks in the Process Monitoring perspective, you can only see the task that is still executing. The reason is that the Schedule task (and therefore its children) is no longer available in the Tasks list.
- You can still access the Schedule that started the task. For this purpose, right-click it and select Activator Executions.
-
With a period turnaround, a new Schedule monitor instance is created. The monitor of the previous instance is frozen. If a task is still Active, its status is not be updated once it ends.
Monitoring the Schedule
When a Schedule object is executed for the first time, the following happens:
- The status of the Schedule is set to Active
- The Schedule is visible in the list of tasks in the Process Monitoring perspective
- Its monitor is available and provides real-time information about the status of the Schedule and of its tasks
- With each period turnaround, a new runID is assigned to the Schedule. This means that each period defined for a Schedule has its own list of Execution Data.
In the Schedule monitor you can change some of the properties of the Schedule object and of its tasks that apply to the current execution. For more information, see Modifying Active Schedules.
You can also modify some parameters of the tasks included in the Schedule. For more information, see Modifying Task Properties in an Active Schedule.
For detailed information about the Schedule monitor, see Monitoring Schedules.
See also: