Adds logs for starting/stopping of the background account hasher (#33903)

This commit is contained in:
Brooks 2023-10-27 13:03:33 -04:00 committed by GitHub
parent 1ce91a56a5
commit 1814b2bc81
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -2926,6 +2926,7 @@ impl AccountsDb {
} }
fn background_hasher(receiver: Receiver<CachedAccount>) { fn background_hasher(receiver: Receiver<CachedAccount>) {
info!("Background account hasher has started");
loop { loop {
let result = receiver.recv(); let result = receiver.recv();
match result { match result {
@ -2936,11 +2937,13 @@ impl AccountsDb {
let _ = (*account).hash(); let _ = (*account).hash();
}; };
} }
Err(_) => { Err(err) => {
info!("Background account hasher is stopping because: {err}");
break; break;
} }
} }
} }
info!("Background account hasher has stopped");
} }
fn start_background_hasher(&mut self) { fn start_background_hasher(&mut self) {