datastore: use new ProcessLocker
To make sure only one process runs garbage collection while having active writers.
This commit is contained in:
@ -227,6 +227,8 @@ impl DataStore {
|
||||
|
||||
if let Ok(ref mut _mutex) = self.gc_mutex.try_lock() {
|
||||
|
||||
let _exclusive_lock = self.chunk_store.try_exclusive_lock()?;
|
||||
|
||||
let mut gc_status = GarbageCollectionStatus::default();
|
||||
gc_status.used_bytes = 0;
|
||||
|
||||
|
Reference in New Issue
Block a user