mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-05 02:27:26 +01:00
TestC2_NoGapDenseLSNEdge asserted that a Realtime NotifyAppend at the dense edge (cursor=10, head=11, lsn=11) emits EmitKindLive, while the shipper's 2 ms timer drain was running. When a tick landed between primary.Write and NotifyAppend, the timer shipped lsn 11 from substrate first (EmitKindBacklog, debt-first per §6.3) and NotifyAppend took the idempotent skip, so the test saw kind=1. That is correct product behavior: the entry ships exactly once at the right LSN, and the kind tag is observability only (WALKindBacklog vs WALKindSessionLive counters; the LiveTail probe is marker-only). - TestC2_NoGapDenseLSNEdge now disables the timer drain and drains the initial backlog with DrainBacklog, so the Live assertion no longer depends on scheduling. - New TestC2_DenseLSNEdge_TimerWinsRace_ShipsOnce pins the other order deterministically: the timer ships the new entry before NotifyAppend arrives; NotifyAppend returns nil and does not emit again. No product change, no timeout changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>