diff --git a/src/ZB.MOM.WW.MxGateway.Contracts/Generated/MxaccessGateway.cs b/src/ZB.MOM.WW.MxGateway.Contracts/Generated/MxaccessGateway.cs index 4b033b5..48601e2 100644 --- a/src/ZB.MOM.WW.MxGateway.Contracts/Generated/MxaccessGateway.cs +++ b/src/ZB.MOM.WW.MxGateway.Contracts/Generated/MxaccessGateway.cs @@ -23592,6 +23592,9 @@ namespace ZB.MOM.WW.MxGateway.Contracts.Proto { /// clients MUST treat a present `replay_gap` as "you missed events — discard /// local state and re-snapshot" and read `requested_after_sequence` / /// `oldest_available_sequence` from it. Unset on every normal MXAccess event. + /// This field is ONLY ever set on events returned from the StreamEvents server + /// stream; it is ALWAYS unset on events in DrainEventsReply (the diagnostic + /// drain path never emits the sentinel). /// Additive (proto3): existing clients that ignore this field continue to /// deserialize the stream unchanged. (Reconnect/replay logic is Task 12; this /// is the contract surface only.) @@ -24491,9 +24494,14 @@ namespace ZB.MOM.WW.MxGateway.Contracts.Proto { public const int OldestAvailableSequenceFieldNumber = 2; private ulong oldestAvailableSequence_; /// - /// The oldest worker_sequence still retained in the replay ring. Events with - /// worker_sequence in (requested_after_sequence, oldest_available_sequence) - /// were evicted and are unrecoverable. + /// The oldest worker_sequence still retained in the replay ring and available + /// for replay. Events with worker_sequence in the open interval + /// (requested_after_sequence, oldest_available_sequence) were evicted and are + /// unrecoverable. oldest_available_sequence itself IS still retained: a client + /// that wishes to resume without incurring another gap MUST set + /// after_worker_sequence = oldest_available_sequence - 1 in the next + /// StreamEventsRequest, which will cause the server to replay starting at + /// oldest_available_sequence (the first retained event). /// [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] diff --git a/src/ZB.MOM.WW.MxGateway.Contracts/Protos/mxaccess_gateway.proto b/src/ZB.MOM.WW.MxGateway.Contracts/Protos/mxaccess_gateway.proto index a56fb3c..3c9d587 100644 --- a/src/ZB.MOM.WW.MxGateway.Contracts/Protos/mxaccess_gateway.proto +++ b/src/ZB.MOM.WW.MxGateway.Contracts/Protos/mxaccess_gateway.proto @@ -725,6 +725,9 @@ message MxEvent { // clients MUST treat a present `replay_gap` as "you missed events — discard // local state and re-snapshot" and read `requested_after_sequence` / // `oldest_available_sequence` from it. Unset on every normal MXAccess event. + // This field is ONLY ever set on events returned from the StreamEvents server + // stream; it is ALWAYS unset on events in DrainEventsReply (the diagnostic + // drain path never emits the sentinel). // Additive (proto3): existing clients that ignore this field continue to // deserialize the stream unchanged. (Reconnect/replay logic is Task 12; this // is the contract surface only.) @@ -750,9 +753,14 @@ message ReplayGap { // The worker_sequence the client asked to resume after // (StreamEventsRequest.after_worker_sequence). uint64 requested_after_sequence = 1; - // The oldest worker_sequence still retained in the replay ring. Events with - // worker_sequence in (requested_after_sequence, oldest_available_sequence) - // were evicted and are unrecoverable. + // The oldest worker_sequence still retained in the replay ring and available + // for replay. Events with worker_sequence in the open interval + // (requested_after_sequence, oldest_available_sequence) were evicted and are + // unrecoverable. oldest_available_sequence itself IS still retained: a client + // that wishes to resume without incurring another gap MUST set + // after_worker_sequence = oldest_available_sequence - 1 in the next + // StreamEventsRequest, which will cause the server to replay starting at + // oldest_available_sequence (the first retained event). uint64 oldest_available_sequence = 2; }