perf: add FileStore buffered writes, O(1) state tracking, and eliminate redundant per-publish work
Implement Go-parity background flush loop (coalesce 16KB/8ms) in MsgBlock/FileStore, replace O(n) GetStateAsync with incremental counters, skip PruneExpired/LoadAsync/ PrunePerSubject when not needed, and bypass RAFT for single-replica streams. Fix counter tracking bugs in RemoveMsg/EraseMsg/TTL expiry and ObjectDisposedException races in flush loop disposal. FileStore optimizations verified with 3112/3112 JetStream tests passing; async publish benchmark remains at ~174 msg/s due to E2E protocol path bottleneck.
This commit is contained in:
@@ -841,6 +841,9 @@ public class InfrastructureGoParityTests
|
||||
Port = port,
|
||||
PingInterval = TimeSpan.FromMilliseconds(100),
|
||||
MaxPingsOut = 3,
|
||||
// Go: TestPing sets o.DisableShortFirstPing = true to avoid the
|
||||
// 2-second grace period and activity-based suppression race.
|
||||
DisableShortFirstPing = true,
|
||||
}, NullLoggerFactory.Instance);
|
||||
|
||||
_ = server.StartAsync(cts.Token);
|
||||
|
||||
Reference in New Issue
Block a user