mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-08-11 14:56:53 +00:00
make most requested changes
This commit is contained in:
committed by
Alex Auvolat
parent
16300bbd89
commit
74373aebcf
@@ -1,4 +1,3 @@
|
||||
#![warn(missing_docs)]
|
||||
#![recursion_limit = "1024"]
|
||||
|
||||
#[macro_use]
|
||||
|
||||
@@ -16,7 +16,6 @@ pub trait TableReplication: Send + Sync {
|
||||
fn write_nodes(&self, hash: &Hash) -> Vec<UUID>;
|
||||
/// Responses needed to consider a write succesfull
|
||||
fn write_quorum(&self) -> usize;
|
||||
// this feels like its write_nodes().len() - write_quorum()
|
||||
fn max_write_errors(&self) -> usize;
|
||||
|
||||
// Accessing partitions, for Merkle tree & sync
|
||||
|
||||
+2
-2
@@ -4,7 +4,7 @@ use garage_util::data::*;
|
||||
|
||||
use crate::crdt::CRDT;
|
||||
|
||||
/// Trait for partitionnable data
|
||||
/// Trait for field used to partition data
|
||||
pub trait PartitionKey {
|
||||
/// Get the key used to partition
|
||||
fn hash(&self) -> Hash;
|
||||
@@ -22,7 +22,7 @@ impl PartitionKey for Hash {
|
||||
}
|
||||
}
|
||||
|
||||
/// Trait for sortable data
|
||||
/// Trait for field used to sort data
|
||||
pub trait SortKey {
|
||||
/// Get the key used to sort
|
||||
fn sort_key(&self) -> &[u8];
|
||||
|
||||
Reference in New Issue
Block a user