aboutsummaryrefslogtreecommitdiff
path: root/src/rpc
diff options
context:
space:
mode:
authorTrinity Pointard <trinity.pointard@gmail.com>2021-04-07 13:39:34 +0200
committerAlex Auvolat <alex@adnab.me>2021-04-27 16:49:07 +0200
commit2812a027ea5a8ac0de22aedce9552c2420c07019 (patch)
tree6ab505b1f5e5d43907c77fcb324df3f9718239ac /src/rpc
parent74373aebcfdfcf5c03e4fb6510d8dd664a0b9b88 (diff)
downloadgarage-2812a027ea5a8ac0de22aedce9552c2420c07019.tar.gz
garage-2812a027ea5a8ac0de22aedce9552c2420c07019.zip
change some more comments and revert changes on TableSchema
Diffstat (limited to 'src/rpc')
-rw-r--r--src/rpc/membership.rs4
-rw-r--r--src/rpc/ring.rs2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/rpc/membership.rs b/src/rpc/membership.rs
index 4fce1a7b..5f7bbc96 100644
--- a/src/rpc/membership.rs
+++ b/src/rpc/membership.rs
@@ -417,8 +417,8 @@ impl System {
}
} else if let Some(id) = id_option {
if let Some(st) = status.nodes.get_mut(id) {
- // TODO this might double-increment the value as the counter is already
- // incremented for any kind of failure in rpc_client
+ // we need to increment failure counter as call was done using by_addr so the
+ // counter was not auto-incremented
st.num_failures.fetch_add(1, Ordering::SeqCst);
if !st.is_up() {
warn!("Node {:?} seems to be down.", id);
diff --git a/src/rpc/ring.rs b/src/rpc/ring.rs
index 04f8b590..bffd7f1f 100644
--- a/src/rpc/ring.rs
+++ b/src/rpc/ring.rs
@@ -28,7 +28,7 @@ const PARTITION_MASK_U16: u16 = ((1 << PARTITION_BITS) - 1) << (16 - PARTITION_B
/// The maximum number of time an object might get replicated
pub const MAX_REPLICATION: usize = 3;
-/// The versionned configurations of all nodes known in the network
+/// The user-defined configuration of the cluster's nodes
#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct NetworkConfig {
/// Map of each node's id to it's configuration