From c2ac66710cdfc84288ba116e29e6cb6619589200 Mon Sep 17 00:00:00 2001 From: Ryo Onodera Date: Sat, 18 Nov 2023 15:08:56 +0900 Subject: [PATCH] save --- scheduler-pool/src/lib.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scheduler-pool/src/lib.rs b/scheduler-pool/src/lib.rs index 104742e60c4b9b..703c6675d23256 100644 --- a/scheduler-pool/src/lib.rs +++ b/scheduler-pool/src/lib.rs @@ -660,10 +660,11 @@ where macro_rules! log_scheduler { ($a:tt) => { info!( - "slot: {}: [{}]({}/{}): state_machine(({}(+{})=>{})/{}) channels(<{} >{}+{} <{}+{})", + "slot: {}: [{}]({}/{}): state_machine(({}(+{})=>{})/{}|{}) channels(<{} >{}+{} <{}+{})", slot, ($a), (if will_end_thread {"T"} else {"-"}), (if will_end_session {"S"} else {"-"}), state_machine.active_task_count(), state_machine.retryable_task_count(), state_machine.handled_task_count(), state_machine.total_task_count(), + state_machine.rescheduled_task_count(), schedulable_transaction_receiver.len(), blocked_transaction_sessioned_sender.len(), idle_transaction_sender.len(), handled_blocked_transaction_receiver.len(), handled_idle_transaction_receiver.len(), @@ -1303,6 +1304,7 @@ struct SchedulingStateMachine { retryable_task_queue: WeightedTaskQueue, active_task_count: usize, handled_task_count: usize, + rescheduled_task_count: usize, total_task_count: usize, } @@ -1323,6 +1325,10 @@ impl SchedulingStateMachine { self.handled_task_count } + fn rescheduled_task_count(&self) -> usize { + self.rescheduled_task_count + } + fn total_task_count(&self) -> usize { self.total_task_count } @@ -1338,6 +1344,7 @@ impl SchedulingStateMachine { } fn schedule_retryable_task(&mut self) -> Option> { + self.rescheduled_task_count += 1; self.retryable_task_queue .pop_last() .and_then(|(_, task)| {