aboutsummaryrefslogtreecommitdiff
path: root/src/table/schema.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2020-07-08 17:34:37 +0200
committerAlex Auvolat <alex@adnab.me>2020-07-08 17:34:37 +0200
commit44dba0e53c7bae0fa16bf48e6022faa95d1159aa (patch)
tree24bd564e6030f82c1ddad7602c12d12a71c0ed8a /src/table/schema.rs
parent64a6eda0d2bb6aae6a6eef60032ab24ae3c37a88 (diff)
downloadgarage-44dba0e53c7bae0fa16bf48e6022faa95d1159aa.tar.gz
garage-44dba0e53c7bae0fa16bf48e6022faa95d1159aa.zip
cargo fmt
Diffstat (limited to 'src/table/schema.rs')
-rw-r--r--src/table/schema.rs11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/table/schema.rs b/src/table/schema.rs
index cedaacac..1914320e 100644
--- a/src/table/schema.rs
+++ b/src/table/schema.rs
@@ -4,7 +4,6 @@ use serde::{Deserialize, Serialize};
use garage_util::data::*;
use garage_util::error::Error;
-
pub trait PartitionKey {
fn hash(&self) -> Hash;
}
@@ -64,11 +63,11 @@ pub trait TableSchema: Send + Sync {
type E: Entry<Self::P, Self::S>;
type Filter: Clone + Serialize + for<'de> Deserialize<'de> + Send + Sync;
- // Action to take if not able to decode current version:
- // try loading from an older version
- fn try_migrate(_bytes: &[u8]) -> Option<Self::E> {
- None
- }
+ // Action to take if not able to decode current version:
+ // try loading from an older version
+ fn try_migrate(_bytes: &[u8]) -> Option<Self::E> {
+ None
+ }
async fn updated(&self, old: Option<Self::E>, new: Option<Self::E>) -> Result<(), Error>;
fn matches_filter(_entry: &Self::E, _filter: &Self::Filter) -> bool {