diff --git a/storage/src/group_commit.rs b/storage/src/group_commit.rs index 725fd07..a83958d 100644 --- a/storage/src/group_commit.rs +++ b/storage/src/group_commit.rs @@ -44,7 +44,7 @@ impl Default for GroupCommitOptions { queue_depth: 1_024, max_batch_pages: 256, max_delay: Duration::from_micros(200), - checkpoint_after_wal_bytes: 64 << 20, + checkpoint_after_wal_bytes: 12 << 20, flush_pages_per_batch: 32, } } diff --git a/storage/src/wal.rs b/storage/src/wal.rs index 2da60c1..8f523d5 100644 --- a/storage/src/wal.rs +++ b/storage/src/wal.rs @@ -17,7 +17,7 @@ const NO_PAGE_ID: u64 = u64::MAX; /// in place, so the routine commit sync never touches file metadata. /// Growing a file on every append makes each sync journal a size change, /// which measured six times slower than syncing data blocks alone. -const WAL_PREALLOCATE_BYTES: u64 = 64 << 20; +const WAL_PREALLOCATE_BYTES: u64 = 16 << 20; /// How far ahead of the append position a segment is zero-filled. /// /// Reserving length with set_len leaves a sparse file, and writing into a