From 253e1a139e694a3d45442c8a982e6a662e1e0f3f Mon Sep 17 00:00:00 2001 From: 4meta5 Date: Thu, 11 Jul 2024 17:31:20 -0400 Subject: [PATCH] move write phase log down so it is not emitted if the execution bails before execute write is called --- chronicle/src/tasks/executor.rs | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/chronicle/src/tasks/executor.rs b/chronicle/src/tasks/executor.rs index 4c2d9deac..af1abff65 100644 --- a/chronicle/src/tasks/executor.rs +++ b/chronicle/src/tasks/executor.rs @@ -211,14 +211,6 @@ where continue; } - event!( - target: TW_LOG, - parent: &span, - Level::INFO, - task_id, - "Running write phase", - ); - let function = match function { Function::RegisterShard { shard_id } => { if let Some(gmp_params) = gmp_params { @@ -279,6 +271,13 @@ where }, _ => function, }; + event!( + target: TW_LOG, + parent: &span, + Level::INFO, + task_id, + "Running write phase", + ); self.task_spawner.execute_write(task_id, function) }, TaskPhase::Read => {