Ferricstore.Store.Shard.Flush (ferricstore v0.3.4)

Copy Markdown View Source

Async and sync Bitcask batch flush, file rotation, hint-file writing, and per-file dead-byte fragmentation tracking.

Summary

Functions

Schedules the periodic :drain_pending timer tick. The tick drains state.pending to the active file via v2_append_batch_nosync — i.e. BEAM memory → kernel page cache. It does NOT fsync. Data-file durability is owned by Ferricstore.Store.BitcaskCheckpointer, which runs on its own (much longer) interval.

Functions

schedule_drain_pending(ms)

@spec schedule_drain_pending(non_neg_integer()) :: reference()

Schedules the periodic :drain_pending timer tick. The tick drains state.pending to the active file via v2_append_batch_nosync — i.e. BEAM memory → kernel page cache. It does NOT fsync. Data-file durability is owned by Ferricstore.Store.BitcaskCheckpointer, which runs on its own (much longer) interval.