mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-08-19 01:36:15 +00:00
block manager: write blocks only to currently active layout version (fix #815)
avoid wastefully writing blocks to nodes that will discard them as soon as the layout migration is finished
This commit is contained in:
@@ -219,6 +219,11 @@ impl LayoutHelper {
|
||||
ret
|
||||
}
|
||||
|
||||
pub fn current_storage_nodes_of(&self, position: &Hash) -> Vec<Uuid> {
|
||||
let ver = self.current();
|
||||
ver.nodes_of(position, ver.replication_factor).collect()
|
||||
}
|
||||
|
||||
pub fn trackers_hash(&self) -> Hash {
|
||||
self.trackers_hash
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user