Tasks
Tasks are atomic units of work initiated by agents. That work can either be performed locally or on a remote system, depending on the type of task. An example of a task that runs local to the agent is a File Operation task that creates, deletes, or moves files on the local system. An example of a task that runs on a remote system is an Email task where the agent is most likely not installed on the same machine as the email server. In this case, the agent does not start the task directly, but submits the request to the email server to run the task.
Task definitions contains the necessary attributes needed to run the task, though it can be defined such that some information is mapped into those attributes at run-time through the use of variables.
Tasks are included within processes (the same task can be included in multiple processes) where they can be scheduled to run automatically through process triggers. However, they can be run manually for testing.
Task Life-cycle
When a task is initially scheduled (a runtime instance of the task is created for some production date), it usually starts off in a SCHEDULED status. However, it could be created to be scheduled with a HOLD status, requiring the operator to release it before it starts to run. It will stay in this initial status until its process goes active and its dependencies are met.
Once all dependencies are met, the task status will briefly change to a WAITING ON AGENT status until an agent is determined (in the case of an agent list) and the agent connection is healthy. The task will then be sent to the agent to be executed.
Once the agent confirms that the task has been received, the task status will be changed to RECEIVED and the task will be handed off to the appropriate agent service for handling.
If the agent service is such that it can activate the task, the task status will be changed to ACTIVE. If the agent service needs to forward the task to another system for execution, the task status will be changed to SUBMITTED. When it is determined that the other system has activated the task, then the task status will be changed to ACTIVE.
When the agent determines the task has completed successfully, the status will be changed to COMPLETED NORMAL. If it has erred, then the status will be changed to ERRED. Some types of tasks may complete but complete with an undesired return value in which case the status will be set to ABNORMAL.
Status | Description |
---|---|
SCHEDULED | The task has been placed in the schedule but is waiting for dependencies to be met. |
HOLD | The task is held until released by an operator. All tasks can be held prior to being activated but some types of tasks can be held while they are active. |
WAITING ON RESOURCES | The task has been setup to require one or more resources before being activated and is waiting for those resources to become available. |
WAITING ON DEPENDENCIES | The task is waiting on the appropriate status of previous items within the process. |
SKIP | The task will be skipped but is in a temporary skip status. |
WAITING ON TIME | The task has been setup with a time window that has not been met yet. |
WAITING ON AGENT | The task is waiting on an agent to have a healthy connection and for the agent service for this task type to be healthy. |
RECEIVED | The agent has received the task start message. |
SUBMITTED | The agent has submitted the task start message to another system to activate. This doesn’t happen with all task types but there are some where the task start message is passed on to some other system for execution and the activation may get queued by that system. |
ACTIVE | The task has been started. |
COMPLETED NORMAL | The task has completed normally. |
COMPLETED ABNORMAL | The task has completed without error but it did not complete as expected. |
ERROR | The task erred prior to activation or while running. |
CANCELLED | The task was cancelled prior to activation. |
ABORTED | The task was cancelled after activation. |
SKIPPED | The task was skipped before being activated. |
TIMED OUT |
The task has been setup with a time window that cannot be met. |
ORPHANED | The task was activated but communication with the task has been lost. This can happen when the agent is taken down while a task is in an active state. |
EXCEPTION | A programmatic error has occurred. This is a rare case. |
Supported Task Services
Applications | Database | Development | File Management | Platforms | Others |
---|---|---|---|---|---|
Hadoop File System (HDFS) Operation |