Skip to content

Commit

Permalink
Merge branch 'shub/commitlog-index' of github.com:clockworklabs/Space…
Browse files Browse the repository at this point in the history
…timeDB into shub/commitlog-index
  • Loading branch information
Shubham8287 committed Sep 24, 2024
2 parents 3dc83fb + 77a3a6c commit e79dcb9
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions crates/commitlog/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,17 @@ pub struct Options {
pub offset_index_interval_bytes: NonZeroU64,
/// If `true`, require that the segment must be synced to disk before an
/// index entry is added.
///
/// Setting this to `false` (the default) will update the index every
/// `offset_index_interval_bytes`, even if the commitlog wasn't synced.
/// This means that the index could contain non-existent entries in the
/// event of a crash.
///
/// Setting it to `true` will update the index when the commitlog is synced,
/// and `offset_index_interval_bytes` have been written.
/// This means that the index could contain fewer index entries than
//// strictly every `offset_index_interval_bytes`.

///
/// Default: false
pub offset_index_require_segment_fsync: bool,
Expand Down

0 comments on commit e79dcb9

Please sign in to comment.