Repository navigation
v0.5.6
API polish and test-coverage expansion
The SegmentStore trait is now sealed (feature-gated under loom; no impact on default-feature consumers), SegmentConfig gains PartialEq/Eq, FlushPolicy gains a reusable validate() method, and BufferStats/DurabilityPolicy/SegmentConfig gain human-readable Display impls. Test coverage expands with 2 loom tests, 2 property tests, 1 stress test, 1 fuzz target, and 2 criterion benchmarks.
No on-disk format change, no new dependency, no API break for default-feature consumers.
Added — API
PartialEq+EqforSegmentConfig(cipher compared byArc::ptr_eq— no key material in comparisons)FlushPolicy::validate()— reusable validation forBatchOrIntervalMinconstraints- Sealed
SegmentStoretrait — prevents downstream implementations (loom feature re-exports the seal marker) Displayimpls forDurabilityPolicy,BufferStats, andSegmentConfig(cipher masked as[set]/[none])#[must_use]onBufferStats#[doc(alias = "backlog")]onpending_count()
Added — test coverage
- 2 loom tests:
for_each_fromPhase 2 snapshot +iter_fromunder concurrent append (loom suite: 12 → 14) - 2 property tests:
publish_disk_statscorrectness (counters vs directory truth after sync + recover),delete_ackedidempotency (overlapping ack ranges + concurrent append) - 1 stress test:
segment_size_statsunder concurrent flush + delete - 1 fuzz target:
fuzz_for_each_from(7 fuzz targets total) - 2 benchmarks:
bench_segment_size_stats(100/1k/10k segments),bench_cipher(AES-256-GCM + XChaCha20-Poly1305 vs baseline)
Changed
- Internal deduplication:
seq_to_indexhelper,BufferInner::pending_count()/latest_sequence()/pending_start()const fns,compute_store_pressureextracted from inline formula BufferStatsDisplay now formats bytes in human-readable binary units (4.0KB,1.0MB)