horaedb icon indicating copy to clipboard operation
horaedb copied to clipboard

feat: Implementing cross-segment read/write for WAL based on local disk

Open dracoooooo opened this issue 1 year ago • 0 comments

Rationale

Improving WAL based on local disk.

This is a follow-up task for #1552.

Detailed Changes

  1. Make MAX_FILE_SIZE configurable.
  2. Allocate enough space when creating a segment to avoid remapping when appending to the segment.​
  3. Add MultiSegmentLogIterator to enable cross-segment reading.
  4. When writing, if the current segment has insufficient space, create a new segment and write to the new segment.​

Test Plan

Unit test.

dracoooooo avatar Aug 23 '24 11:08 dracoooooo