SHOW ROUTINE LOAD TASK
Description
Shows the execution information of load tasks within a Routine Load job.
note
-
You can manage Routine Load jobs that run on StarRocks tables only as a user who has the INSERT privilege on those StarRocks tables. If you do not have the INSERT privilege, follow the instructions provided in GRANT to grant the INSERT privilege to the user that you use to connect to your StarRocks cluster.
Syntax
SHOW ROUTINE LOAD TASK
[ FROM <db_name>]
[ WHERE JobName = <job_name> ]
note
You can add the \G
option to the statement (such as SHOW ROUTINE LOAD TASK WHERE JobName = <job_name>\G
) to vertically display the return result rather than in the usual horizontal table format.
Parameters
Parameter | Required | Description |
---|---|---|
db_name | No | The name of the database to which the Routine Load job belongs. |
JobName | No | The name of the Routine Load job. |
Output
Parameter | Description |
---|---|
TaskId | The globally unique ID of the load task, automatically generated by StarRocks. |
TxnId | The ID of the transaction to which the load task belongs. |
TxnStatus | The status of the transaction to which the load task belongs. UNKNOWN indicates that the transaction is not started yet, possibly because the load task is not dispatched or executed. |
JobId | The ID of the load job. |
CreateTime | The date and time when the load task was created. |
LastScheduledTime | The date and time when the load task was last scheduled. |
ExecuteStartTime | The date and time when the load task was executed. |
Timeout | The timeout period for the load task, controlled by the FE parameter routine_load_task_timeout_second and the task_timeout_second parameter in [job_properties](./CREATE_ROUTINE_LO../../data-manipulation/CREATE_ROUTINE_LOAD.mdr the Routine Load job. |
BeId | The ID of the BE that executes the load task. |
DataSourceProperties | The load task's progress (measured in the offset) of consuming messages in partitions of the topic. |
Message | The information returned for the load task, including task error information. |
Examples
View all load tasks in the Routine Load job example_tbl_ordertest
.
MySQL [example_db]> SHOW ROUTINE LOAD TASK WHERE JobName = "example_tbl_ordertest";
+--------------------------------------+-------+-----------+-------+---------------------+---------------------+------------------+---------+------+------------------------------------+-----------------------------------------------------------------------------+
| TaskId | TxnId | TxnStatus | JobId | CreateTime | LastScheduledTime | ExecuteStartTime | Timeout | BeId | DataSourceProperties | Message |
+--------------------------------------+-------+-----------+-------+---------------------+---------------------+------------------+---------+------+------------------------------------+-----------------------------------------------------------------------------+
| abde6998-c19a-43d6-b48c-6ca7e14144a3 | -1 | UNKNOWN | 10208 | 2023-12-22 12:46:10 | 2023-12-22 12:47:00 | NULL | 60 | -1 | Progress:{"0":6},LatestOffset:null | there is no new data in kafka/pulsar, wait for 10 seconds to schedule again |
+--------------------------------------+-------+-----------+-------+---------------------+---------------------+------------------+---------+------+------------------------------------+-----------------------------------------------------------------------------+
1 row in set (0.00 sec)