Fix E2E test gaps and add comprehensive E2E + parity test suites
- Fix pull consumer fetch: send original stream subject in HMSG (not inbox) so NATS client distinguishes data messages from control messages - Fix MaxAge expiry: add background timer in StreamManager for periodic pruning - Fix JetStream wire format: Go-compatible anonymous objects with string enums, proper offset-based pagination for stream/consumer list APIs - Add 42 E2E black-box tests (core messaging, auth, TLS, accounts, JetStream) - Add ~1000 parity tests across all subsystems (gaps closure) - Update gap inventory docs to reflect implementation status
This commit is contained in:
@@ -0,0 +1,58 @@
|
||||
namespace NATS.Server.JetStream;
|
||||
|
||||
/// <summary>
|
||||
/// API usage counters for JetStream.
|
||||
/// Go reference: server/jetstream.go JetStreamAPIStats.
|
||||
/// </summary>
|
||||
public sealed class JetStreamApiStats
|
||||
{
|
||||
public int Level { get; set; }
|
||||
public ulong Total { get; set; }
|
||||
public ulong Errors { get; set; }
|
||||
public int Inflight { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Per-tier JetStream resource view.
|
||||
/// Go reference: server/jetstream.go JetStreamTier.
|
||||
/// </summary>
|
||||
public sealed class JetStreamTier
|
||||
{
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public long Memory { get; set; }
|
||||
public long Store { get; set; }
|
||||
public int Streams { get; set; }
|
||||
public int Consumers { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Per-account JetStream limits.
|
||||
/// Go reference: server/jetstream.go JetStreamAccountLimits.
|
||||
/// </summary>
|
||||
public sealed class JetStreamAccountLimits
|
||||
{
|
||||
public long MaxMemory { get; set; }
|
||||
public long MaxStore { get; set; }
|
||||
public int MaxStreams { get; set; }
|
||||
public int MaxConsumers { get; set; }
|
||||
public int MaxAckPending { get; set; }
|
||||
public long MemoryMaxStreamBytes { get; set; }
|
||||
public long StoreMaxStreamBytes { get; set; }
|
||||
public bool MaxBytesRequired { get; set; }
|
||||
public Dictionary<string, JetStreamTier> Tiers { get; set; } = new(StringComparer.Ordinal);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Server-level JetStream usage stats.
|
||||
/// Go reference: server/jetstream.go JetStreamStats.
|
||||
/// </summary>
|
||||
public sealed class JetStreamStats
|
||||
{
|
||||
public long Memory { get; set; }
|
||||
public long Store { get; set; }
|
||||
public long ReservedMemory { get; set; }
|
||||
public long ReservedStore { get; set; }
|
||||
public int Accounts { get; set; }
|
||||
public int HaAssets { get; set; }
|
||||
public JetStreamApiStats Api { get; set; } = new();
|
||||
}
|
||||
Reference in New Issue
Block a user