fix: don't bump relay error count if exiting gracefully

This commit is contained in:
Mike Dilger 2022-12-24 20:13:50 +13:00
parent 79d2e2ca3a
commit 7e2766ac95

View File

@ -63,13 +63,13 @@ impl Minion {
// Catch errors, Return nothing.
if let Err(e) = self.handle_inner().await {
error!("ERROR handling {}: {}", &self.url, e);
}
// Bump the failure count for the relay.
self.dbrelay.failure_count += 1;
if let Err(e) = DbRelay::update(self.dbrelay.clone()).await {
error!("ERROR bumping relay failure count {}: {}", &self.url, e);
}
}
debug!("Minion exiting: {}", self.url);
}