Make sure pending updates are process when restarting the UpdateStore

This commit is contained in:
Clément Renault 2020-11-09 17:33:07 +01:00
parent 8ffdfa72e3
commit 45ae086974
No known key found for this signature in database
GPG Key ID: 92ADA4E935E71FA4

View File

@ -36,6 +36,9 @@ impl<M: 'static, N: 'static> UpdateStore<M, N> {
let processed_meta = env.create_database(Some("processed-meta"))?; let processed_meta = env.create_database(Some("processed-meta"))?;
let (notification_sender, notification_receiver) = crossbeam_channel::bounded(1); let (notification_sender, notification_receiver) = crossbeam_channel::bounded(1);
// Send a first notification to trigger the process.
let _ = notification_sender.send(());
let update_store = Arc::new(UpdateStore { let update_store = Arc::new(UpdateStore {
env, env,
pending, pending,