Log errors in index self_trigger

This commit is contained in:
Antoine Gersant 2020-01-18 14:25:10 -08:00
parent e64435efa5
commit 50421e91d6

View file

@ -482,7 +482,10 @@ pub fn self_trigger(db: &DB, command_buffer: &Arc<CommandSender>) {
.map_err(|e| Error::new(e))
})
.map(|s: MiscSettings| s.index_sleep_duration_seconds)
.unwrap_or(1800) // TODO log error
.unwrap_or_else(|e| {
error!("Could not retrieve index sleep duration: {}", e);
1800
})
};
thread::sleep(time::Duration::from_secs(sleep_duration as u64));
}