aboutsummaryrefslogtreecommitdiff
path: root/src/block/repair.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-12-14 15:25:29 +0100
committerAlex Auvolat <alex@adnab.me>2022-12-14 15:25:29 +0100
commitdfc131850a09e7ceacfa98315adbef156e07e9ca (patch)
treeb9684958e211e0dd0389c12a166c9d1af5e8b5f9 /src/block/repair.rs
parentd4af27f920ce48a60f2073e98b17bdf963241686 (diff)
downloadgarage-dfc131850a09e7ceacfa98315adbef156e07e9ca.tar.gz
garage-dfc131850a09e7ceacfa98315adbef156e07e9ca.zip
Simplified and more aggressive worker exit logic
Diffstat (limited to 'src/block/repair.rs')
-rw-r--r--src/block/repair.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/block/repair.rs b/src/block/repair.rs
index 1878027e..f5515d4e 100644
--- a/src/block/repair.rs
+++ b/src/block/repair.rs
@@ -148,7 +148,7 @@ impl Worker for RepairWorker {
}
}
- async fn wait_for_work(&mut self, _must_exit: &watch::Receiver<bool>) -> WorkerState {
+ async fn wait_for_work(&mut self) -> WorkerState {
unreachable!()
}
}
@@ -341,7 +341,7 @@ impl Worker for ScrubWorker {
}
}
- async fn wait_for_work(&mut self, _must_exit: &watch::Receiver<bool>) -> WorkerState {
+ async fn wait_for_work(&mut self) -> WorkerState {
let (wait_until, command) = match &self.work {
ScrubWorkerState::Running(_) => return WorkerState::Busy,
ScrubWorkerState::Paused(_, resume_time) => (*resume_time, ScrubWorkerCommand::Resume),