From f54bb6c2c757bfe43aae8d6adbedec1aab31e5c4 Mon Sep 17 00:00:00 2001 From: Shanicky Chen <> Date: Fri, 17 May 2024 17:19:51 +0800 Subject: [PATCH] Remove typecast for ROOT_TASK_* constants --- src/frontend/src/scheduler/distributed/query.rs | 4 ++-- src/frontend/src/scheduler/distributed/stage.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/frontend/src/scheduler/distributed/query.rs b/src/frontend/src/scheduler/distributed/query.rs index 0a8244086109b..165bdcee6476b 100644 --- a/src/frontend/src/scheduler/distributed/query.rs +++ b/src/frontend/src/scheduler/distributed/query.rs @@ -392,12 +392,12 @@ impl QueryRunner { let root_task_id_prost = TaskIdPb { query_id: self.query.query_id.clone().id, stage_id: self.query.root_stage_id(), - task_id: ROOT_TASK_ID as u64, + task_id: ROOT_TASK_ID, }; TaskOutputIdPb { task_id: Some(root_task_id_prost), - output_id: ROOT_TASK_OUTPUT_ID as u64, + output_id: ROOT_TASK_OUTPUT_ID, } }; diff --git a/src/frontend/src/scheduler/distributed/stage.rs b/src/frontend/src/scheduler/distributed/stage.rs index 128c4f75b908c..c727d2e61b1ff 100644 --- a/src/frontend/src/scheduler/distributed/stage.rs +++ b/src/frontend/src/scheduler/distributed/stage.rs @@ -584,7 +584,7 @@ impl StageRunner { let root_stage_id = self.stage.id; // Currently, the dml or table scan should never be root fragment, so the partition is None. // And root fragment only contain one task. - let plan_fragment = self.create_plan_fragment(ROOT_TASK_ID as u64, None); + let plan_fragment = self.create_plan_fragment(ROOT_TASK_ID, None); let plan_node = plan_fragment.root.unwrap(); let task_id = TaskIdBatch { query_id: self.stage.query_id.id.clone(),