To add a bean-mode task, first develop a job handler based on the XXL-JOB executor source code, and then record the value defined by @JobHandler for the JobHandler class in the executor.
On the top navigation bar, select Cloud Services, and then select Distributed Task Scheduling Platform from the Middleware menu.
From the left navigation pane, select Task Management.
Click Create Task to add a task.
Configure the task parameters as needed.
Table-1 Configuring task parameters
Parameter |
Description |
Executor |
Select an executor to bind the task and the executor. You must bind a task to an executor. An executor can be bound to multiple tasks. In task scheduling, the scheduling platform can automatically discover the registered executors and thus discover the tasks bound to the executors. |
Task Description |
Enter the description for the task to facilitate task searching. |
Cron Expression |
Specify a Cron expression to define the execution time for the task. For information about the format and syntax of a Cron expression string, see the Cron related documentation. The Business Apps platform has converted the complicated Cron expression string configuration into visual configuration. Click the input box to activate the configuration interface. Select the time conditions, and the Cron expression string will be automatically generated.
|
Scheduling Algorithm |
Select the scheduling algorithm used to select an executor instance for the task when the executor is a cluster of multiple executor instances.
|
Operation Mode |
|
Block Handling |
Specify the policy used to process a scheduling task request when scheduling tasks are congested in the executor.
|
Job Handler |
Specify the job handler for the task. This field is required when the operation mode is bean. It represents the value defined by @JobHandler for the JobHandler class in the executor. |
Child Task IDs |
Specify the child task IDs. After a task is executed successfully, its child tasks (identified by child task IDs) will also be executed once automatically. The ID of a task is automatically generated after the task is added. You can obtain task IDs from the task list. |
Task Retries |
Specify the number of scheduling retries. If all the retries fail, the task fails. |
Task Timeout |
Specify the task execution timeout time. If the execution of a task exceeds the timeout time, the task will be stopped. |
Send Alarms via Emails |
Specify the email addresses used to receive task failure alarms. Separate the email addresses by commas. |
Task Parameter |
Configure the parameter required for execution of the task. |