diff options
author | Alex Auvolat <alex@adnab.me> | 2023-06-09 16:23:21 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2023-06-09 16:23:21 +0200 |
commit | e7e164a280dfc1c4adf9d6da6f3b2a9674eca4bd (patch) | |
tree | 610408aedb12063faf49c28de0f3071f4e1f703e /src/util | |
parent | 1e466b11eb9a3d5de2b8247fc6b635f9278bc3ac (diff) | |
download | garage-e7e164a280dfc1c4adf9d6da6f3b2a9674eca4bd.tar.gz garage-e7e164a280dfc1c4adf9d6da6f3b2a9674eca4bd.zip |
Make fsync an option for meta and data
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/config.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/util/config.rs b/src/util/config.rs index 77952356..009f0574 100644 --- a/src/util/config.rs +++ b/src/util/config.rs @@ -15,6 +15,13 @@ pub struct Config { /// Path where to store data. Can be slower, but need higher volume pub data_dir: PathBuf, + /// Whether to fsync after all metadata transactions (disabled by default) + #[serde(default)] + pub metadata_fsync: bool, + /// Whether to fsync after all data block writes (disabled by default) + #[serde(default)] + pub data_fsync: bool, + /// Size of data blocks to save to disk #[serde(default = "default_block_size")] pub block_size: usize, |