aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2021-03-11 18:45:26 +0100
committerAlex Auvolat <alex@adnab.me>2021-03-11 18:45:26 +0100
commitdb7a9d4948d41e4b641f9c50f6ff8921a436431d (patch)
treefcc2196c07ed797979ca6f69ccdebff8e6a6c02c /src
parent046b649bcc3b147140fc2b0af0e071d3dd1b2c8d (diff)
downloadgarage-db7a9d4948d41e4b641f9c50f6ff8921a436431d.tar.gz
garage-db7a9d4948d41e4b641f9c50f6ff8921a436431d.zip
Tiny changes
Diffstat (limited to 'src')
-rw-r--r--src/table/sync.rs9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/table/sync.rs b/src/table/sync.rs
index 9c37c286..42321ac6 100644
--- a/src/table/sync.rs
+++ b/src/table/sync.rs
@@ -49,7 +49,6 @@ pub(crate) enum SyncRPC {
CkNoDifference,
GetNode(MerkleNodeKey),
Node(MerkleNodeKey, MerkleNode),
- Items(Vec<Arc<ByteBuf>>),
}
struct SyncTodo {
@@ -119,7 +118,7 @@ where
select! {
new_ring_r = s_ring_recv => {
if new_ring_r.is_some() {
- debug!("({}) Adding ring difference to syncer todo list", self.data.name);
+ debug!("({}) Ring changed, adding full sync to syncer todo list", self.data.name);
self.add_full_sync();
}
}
@@ -142,7 +141,7 @@ where
_ = s_timeout => {
if nothing_to_do_since.map(|t| Instant::now() - t >= ANTI_ENTROPY_INTERVAL).unwrap_or(false) {
nothing_to_do_since = None;
- debug!("({}) Adding full sync to syncer todo list", self.data.name);
+ debug!("({}) Interval passed, adding full sync to syncer todo list", self.data.name);
self.add_full_sync();
}
}
@@ -330,6 +329,10 @@ where
}
// ======= SYNCHRONIZATION PROCEDURE -- DRIVER SIDE ======
+ // The driver side is only concerned with sending out the item it has
+ // and the other side might not have. Receiving items that differ from one
+ // side to the other will happen when the other side syncs with us,
+ // which they also do regularly.
fn get_root_ck(&self, range: PartitionRange) -> Result<RootCk, Error> {
let begin = u16::from_be_bytes(range.begin);