aboutsummaryrefslogtreecommitdiff
path: root/src/data.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2020-04-08 22:00:41 +0200
committerAlex Auvolat <alex@adnab.me>2020-04-08 22:00:41 +0200
commitbacc76a057bcd90d61bfe3584bd3cdbadc748364 (patch)
treeb9a55aec2ef1fa7660bf539c02e651ea4053688c /src/data.rs
parentd50edcdb4f8b8ec00b1f0ffb6a3ebbb0e5afdc1f (diff)
downloadgarage-bacc76a057bcd90d61bfe3584bd3cdbadc748364.tar.gz
garage-bacc76a057bcd90d61bfe3584bd3cdbadc748364.zip
Some work in actually storing things
Diffstat (limited to 'src/data.rs')
-rw-r--r--src/data.rs24
1 files changed, 2 insertions, 22 deletions
diff --git a/src/data.rs b/src/data.rs
index 3c71b782..bbe9aa1d 100644
--- a/src/data.rs
+++ b/src/data.rs
@@ -106,7 +106,7 @@ pub struct NetworkConfigEntry {
// Data management
-pub const INLINE_THRESHOLD: usize = 2048;
+pub const INLINE_THRESHOLD: usize = 3072;
#[derive(Debug, Serialize, Deserialize)]
pub struct SplitpointMeta {
@@ -118,27 +118,7 @@ pub struct SplitpointMeta {
pub deleted: bool,
}
-#[derive(Clone, Debug, Serialize, Deserialize)]
-pub struct VersionMeta {
- pub bucket: String,
- pub key: String,
-
- pub timestamp: u64,
- pub uuid: UUID,
-
- pub mime_type: String,
- pub size: u64,
- pub is_complete: bool,
-
- pub data: VersionData,
-}
-
-#[derive(Clone, Debug, Serialize, Deserialize)]
-pub enum VersionData {
- DeleteMarker,
- Inline(#[serde(with="serde_bytes")] Vec<u8>),
- FirstBlock(Hash),
-}
+pub use crate::version_table::*;
#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct BlockMeta {