aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/ring.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2021-02-21 15:24:30 +0100
committerAlex Auvolat <alex@adnab.me>2021-02-21 15:24:30 +0100
commitb1b640ae8bd8d2ed7c128cb3f90e3e56226a5560 (patch)
tree55a703af2b8816b5c2e1aeb635db3538daa96a75 /src/rpc/ring.rs
parente59322041a0f894db0dfbd32805303b64048c810 (diff)
downloadgarage-b1b640ae8bd8d2ed7c128cb3f90e3e56226a5560.tar.gz
garage-b1b640ae8bd8d2ed7c128cb3f90e3e56226a5560.zip
rename hash() to sha256sum(), we might want to change it at some places
Diffstat (limited to 'src/rpc/ring.rs')
-rw-r--r--src/rpc/ring.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rpc/ring.rs b/src/rpc/ring.rs
index 1646afbf..1df0bb41 100644
--- a/src/rpc/ring.rs
+++ b/src/rpc/ring.rs
@@ -56,7 +56,7 @@ impl Ring {
let datacenter_idx = datacenters.iter().enumerate().find(|(_, dc)| *dc == datacenter).unwrap().0;
for i in 0..config.n_tokens {
- let location = hash(format!("{} {}", hex::encode(&id), i).as_bytes());
+ let location = sha256sum(format!("{} {}", hex::encode(&id), i).as_bytes());
new_ring.push(RingEntry {
location: location.into(),