aboutsummaryrefslogtreecommitdiff
path: root/src/table/table.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/table/table.rs')
-rw-r--r--src/table/table.rs20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/table/table.rs b/src/table/table.rs
index 50e8739a..94bacc60 100644
--- a/src/table/table.rs
+++ b/src/table/table.rs
@@ -8,14 +8,14 @@ use futures::stream::*;
use serde::{Deserialize, Serialize};
use serde_bytes::ByteBuf;
-use crate::data::*;
-use crate::error::Error;
+use garage_util::data::*;
+use garage_util::error::Error;
-use crate::rpc::membership::{Ring, System};
-use crate::rpc::rpc_client::*;
-use crate::rpc::rpc_server::*;
+use garage_rpc::membership::{Ring, System};
+use garage_rpc::rpc_client::*;
+use garage_rpc::rpc_server::*;
-use crate::table::table_sync::*;
+use crate::table_sync::*;
const TABLE_RPC_TIMEOUT: Duration = Duration::from_secs(10);
@@ -78,14 +78,14 @@ impl PartitionKey for EmptyKey {
}
}
-impl<T: AsRef<str>> PartitionKey for T {
+impl PartitionKey for String {
fn hash(&self) -> Hash {
- hash(self.as_ref().as_bytes())
+ hash(self.as_bytes())
}
}
-impl<T: AsRef<str>> SortKey for T {
+impl SortKey for String {
fn sort_key(&self) -> &[u8] {
- self.as_ref().as_bytes()
+ self.as_bytes()
}
}