docs: fill missing XML docs and strip tracking IDs from src comments
Clears CommentChecker findings in src/ (3,280 -> 209, the remainder being false positives like PLC-5/IEEE-754/M0.0) by adding missing summaries/params/returns, normalising inheritdoc usage, and removing Gitea/review tracking IDs while keeping the rationale they annotated. Comment-only: comment-stripped sources are identical to the parent commit.
This commit is contained in:
@@ -89,7 +89,7 @@ public sealed class ContinuousHistorizationOptions
|
||||
/// dominant term in how fast the outbox can drain. The window bounds how many of those
|
||||
/// round-trips are outstanding at once, so a large tag count cannot flood the gateway. Nothing
|
||||
/// about the ack changes: the pass is still acked all-or-nothing after every group has
|
||||
/// reported, and the Gitea #538 per-tag quarantine still keys on "another group wrote this
|
||||
/// reported, and the per-tag quarantine still keys on "another group wrote this
|
||||
/// pass".
|
||||
/// </para>
|
||||
/// </summary>
|
||||
@@ -99,7 +99,7 @@ public sealed class ContinuousHistorizationOptions
|
||||
/// Maximum un-acked outbox entries before the drop-oldest capacity policy kicks in; <c>0</c>
|
||||
/// means unbounded.
|
||||
/// <para>
|
||||
/// Defaults to 500,000 (Gitea #538) — roughly 50 MB of FasterLog, and hours-to-days of
|
||||
/// Defaults to 500,000 — roughly 50 MB of FasterLog, and hours-to-days of
|
||||
/// backlog depending on tag count and update rate. It is a disk backstop for the one case
|
||||
/// the per-tag quarantine cannot resolve: a historian that is unreachable or refusing
|
||||
/// <em>every</em> write, where nothing proves any particular tag is at fault, so the
|
||||
@@ -110,7 +110,7 @@ public sealed class ContinuousHistorizationOptions
|
||||
public int Capacity { get; init; } = 500_000;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #538: consecutive failed drain passes a single historian tag may accumulate — counted
|
||||
/// consecutive failed drain passes a single historian tag may accumulate — counted
|
||||
/// only across passes where <em>other</em> tags wrote successfully, so a backend outage never
|
||||
/// advances it — before that tag's queued entries are discarded and the FIFO head is allowed to
|
||||
/// advance. Defaults to 5; clamped to at least 1 by the recorder.
|
||||
@@ -130,8 +130,8 @@ public sealed class ContinuousHistorizationOptions
|
||||
public double MaxBackoffSeconds { get; init; } = 30;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #672: when <c>true</c> (the default), a redundant node whose capture is stood down for its
|
||||
/// mesh-partner Primary (Gitea #537) resumes capturing as soon as the cluster failure detector reports
|
||||
/// when <c>true</c> (the default), a redundant node whose capture is stood down for its
|
||||
/// mesh-partner Primary resumes capturing as soon as the cluster failure detector reports
|
||||
/// that Primary <b>unreachable</b>, instead of waiting for auto-down and a fresh redundancy snapshot.
|
||||
/// <para>
|
||||
/// A crashed Primary otherwise leaves a capture hole of failure-detection + auto-down (~25 s on the
|
||||
@@ -141,7 +141,7 @@ public sealed class ContinuousHistorizationOptions
|
||||
/// detection onward, and a briefly-unreachable-but-alive Primary overlaps the standby. SqlServer and
|
||||
/// QuestDB absorb a duplicate of a source-timestamped sample idempotently; a driver with no source
|
||||
/// timestamp (e.g. Modbus, stamped with each node's own poll time) writes a duplicate row on every
|
||||
/// backend, and the Gateway backend stores duplicates. <c>false</c> restores the pre-#672 behaviour.
|
||||
/// backend, and the Gateway backend stores duplicates. <c>false</c> restores the previous behaviour.
|
||||
/// Only the historization capture verdict is affected — never the alarm drain or the Primary data-plane
|
||||
/// gate.
|
||||
/// </para>
|
||||
|
||||
@@ -30,7 +30,7 @@ namespace ZB.MOM.WW.OtOpcUa.Runtime.Historian;
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// <b>Comms loss IS historized (as an outage marker).</b> On a driver disconnect
|
||||
/// <c>DriverHostActor.FanCommsLossToDependencyMux</c> (#481) fans <c>(null, BadNoCommunication)</c>
|
||||
/// <c>DriverHostActor.FanCommsLossToDependencyMux</c> fans <c>(null, BadNoCommunication)</c>
|
||||
/// through the mux for every value ref of the driver, so the recorder receives it like any other
|
||||
/// sample (it cannot, and does not try to, tell it apart from a driver's own null + Bad publish).
|
||||
/// When the backend supports <see cref="HistorianValueKind.Empty"/> it is stored as an
|
||||
@@ -79,7 +79,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// <param name="Acked">Entries durably written and truncated away.</param>
|
||||
/// <param name="Attempted">Entries in the peeked batch.</param>
|
||||
/// <param name="Abandoned">Entries discarded because their tag is poison — see
|
||||
/// <see cref="DrainOnceAsync"/> (Gitea #538). Counted within <paramref name="Attempted"/>.</param>
|
||||
/// <see cref="DrainOnceAsync"/>. Counted within <paramref name="Attempted"/>.</param>
|
||||
private sealed record DrainResult(bool Success, int Acked, int Attempted, int Abandoned = 0);
|
||||
|
||||
/// <summary>Ask the recorder for its current counters (used by the meter/health wiring).</summary>
|
||||
@@ -111,7 +111,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// credit that prefix. Those entries still drain; they are simply never counted here.</param>
|
||||
/// <param name="DroppedUnsupportedKind">Lifetime count of values dropped because they are not historizable
|
||||
/// (arrays, references) or their kind is not one the backend supports. On a numeric-only backend this
|
||||
/// includes the #481 comms-loss stamps (<c>null</c> + <c>BadNoCommunication</c> ⇒ Empty): every driver
|
||||
/// includes the comms-loss stamps (<c>null</c> + <c>BadNoCommunication</c> ⇒ Empty): every driver
|
||||
/// disconnect adds one per historized ref of that driver.</param>
|
||||
/// <param name="OutboxDropped">Lifetime count of entries the outbox dropped on capacity overflow.</param>
|
||||
/// <param name="OutboxAppendFailures">Lifetime count of FAILED BATCH APPENDS at the durable boundary —
|
||||
@@ -121,9 +121,9 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// may still have left entries durably queued that drain normally — see <see cref="IngestAsync"/>.</param>
|
||||
/// <param name="LastDrainSucceeded">Whether the most recent drain pass acked cleanly.</param>
|
||||
/// <param name="SuppressedNotPrimary">Lifetime count of values not captured because this node is
|
||||
/// the Secondary of a pair whose Primary records the same refs (Gitea #537).</param>
|
||||
/// the Secondary of a pair whose Primary records the same refs.</param>
|
||||
/// <param name="AbandonedEntries">Lifetime count of entries discarded because their historian tag
|
||||
/// kept failing while other tags were writing successfully (Gitea #538).</param>
|
||||
/// kept failing while other tags were writing successfully.</param>
|
||||
/// <param name="IngestFaults">Lifetime count of values dropped because the per-value gate/coercion step
|
||||
/// threw — distinct from <paramref name="DroppedUnsupportedKind"/>, which counts values the backend
|
||||
/// cannot carry. Non-zero here means an ingest dependency is faulting (most
|
||||
@@ -156,11 +156,11 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
private readonly TimeSpan _minBackoff;
|
||||
private readonly TimeSpan _maxBackoff;
|
||||
|
||||
/// <summary>Gitea #537: "should this node be capturing right now?". Supplied by the Runtime wiring
|
||||
/// <summary>"should this node be capturing right now?". Supplied by the Runtime wiring
|
||||
/// from the redundancy role view; a null gate (tests, single-node graphs) always captures.</summary>
|
||||
private readonly Func<bool> _captureGate;
|
||||
|
||||
/// <summary>Gitea #538: consecutive failed write passes a tag may accumulate — while OTHER tags are
|
||||
/// <summary>Consecutive failed write passes a tag may accumulate — while OTHER tags are
|
||||
/// writing successfully — before its queued entries are abandoned so the FIFO head can advance.</summary>
|
||||
private readonly int _maxWriteAttempts;
|
||||
|
||||
@@ -218,10 +218,10 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// <param name="drainInterval">Steady drain cadence; also the post-success reschedule.</param>
|
||||
/// <param name="minBackoff">Initial retry backoff after a failed drain.</param>
|
||||
/// <param name="maxBackoff">Cap on the exponential retry backoff.</param>
|
||||
/// <param name="captureGate">Gitea #537: "should this node be capturing right now?", read per
|
||||
/// <param name="captureGate">"should this node be capturing right now?", read per
|
||||
/// value. Null (the default) always captures — the correct posture for a single-node deployment
|
||||
/// and for tests.</param>
|
||||
/// <param name="maxWriteAttempts">Gitea #538: consecutive failed write passes one tag may
|
||||
/// <param name="maxWriteAttempts">Consecutive failed write passes one tag may
|
||||
/// accumulate, while other tags are succeeding, before its entries are abandoned.</param>
|
||||
/// <param name="drainConcurrency">Max historian tags one drain pass writes concurrently (must be
|
||||
/// positive; 1 is the fully sequential drain).</param>
|
||||
@@ -254,9 +254,9 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// <param name="drainInterval">Steady drain cadence; also the post-success reschedule.</param>
|
||||
/// <param name="minBackoff">Initial retry backoff after a failed drain.</param>
|
||||
/// <param name="maxBackoff">Cap on the exponential retry backoff.</param>
|
||||
/// <param name="captureGate">Gitea #537: "should this node be capturing right now?", read per
|
||||
/// <param name="captureGate">"should this node be capturing right now?", read per
|
||||
/// value. Null (the default) always captures.</param>
|
||||
/// <param name="maxWriteAttempts">Gitea #538: consecutive failed write passes one tag may
|
||||
/// <param name="maxWriteAttempts">Consecutive failed write passes one tag may
|
||||
/// accumulate, while other tags are succeeding, before its entries are abandoned. Clamped to at
|
||||
/// least 1.</param>
|
||||
/// <param name="drainConcurrency">Max historian tags one drain pass writes concurrently. Clamped to
|
||||
@@ -365,7 +365,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// <b>The gates stay per value.</b> The ref filter, the Gitea #537 capture gate and the typed-value
|
||||
/// <b>The gates stay per value.</b> The ref filter, the capture gate and the typed-value
|
||||
/// coercion + kind gate are evaluated for each item in turn — the capture gate in particular is a live read
|
||||
/// per value, never hoisted to once per batch, so a promotion resumes capture on the very next
|
||||
/// sample (pinned by <c>The_capture_gate_is_re_read_per_value_so_promotion_resumes_capture</c>).
|
||||
@@ -377,7 +377,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
/// <c>IngestFaults</c>, logged by category, and the loop continues with the next item. Left
|
||||
/// unguarded it would escape the handler into supervision, discarding every item after it in the
|
||||
/// burst AND restarting the actor — which in production discards the historized-ref set (see the
|
||||
/// #491 note below).
|
||||
/// note below).
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// <b>Append failure is batch-wide, and it is NOT a whole-burst loss.</b> A failed group commit
|
||||
@@ -403,7 +403,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
// commit (PerEntry commit mode), so it does; a fake outbox returning ValueTask.CompletedTask
|
||||
// completes synchronously, the continuation runs inline with the context still installed, and the
|
||||
// bug is invisible. That is exactly how it reached production — see the yielding fake in
|
||||
// ContinuousHistorizationRecorderTests. Live-caught on the docker-dev rig (Gitea #491), where the
|
||||
// ContinuousHistorizationRecorderTests. Live-caught on the docker-dev rig, where the
|
||||
// throw escaped the handler into supervision: the actor restarted, and because production seeds an
|
||||
// EMPTY ref set (the deployed set arrives later via UpdateHistorizedRefs), the restart silently
|
||||
// dropped every historized ref — so historization stopped dead after the FIRST value.
|
||||
@@ -524,7 +524,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
return;
|
||||
}
|
||||
|
||||
// Gitea #537: both nodes of a redundant pair serve the same address space and see the same mux
|
||||
// Both nodes of a redundant pair serve the same address space and see the same mux
|
||||
// fan-out, so an ungated recorder writes every sample TWICE (measured on the docker-dev central
|
||||
// pair: the gateway's write counter advanced twice per value, and halved when one node stopped).
|
||||
// The gate closes only on a node whose pair partner is the Primary and is recording the same
|
||||
@@ -745,7 +745,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
catch (OperationCanceledException) when (ct.IsCancellationRequested)
|
||||
{
|
||||
// Shutdown cut this write short. That is a property of the PASS, not of the tag:
|
||||
// swallowed as `ok = false` it becomes a Gitea #538 consecutive failure, and when a
|
||||
// swallowed as `ok = false` it becomes a consecutive failure, and when a
|
||||
// sibling group already wrote this pass the fold books it — so a routine node stop
|
||||
// can tip a perfectly HEALTHY tag over its attempt budget and discard its queued
|
||||
// samples on the way out. Rethrow so it propagates through Task.WhenAll to the
|
||||
@@ -759,7 +759,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
// cannot fail the whole drain task (and, now, cannot fault the WhenAll either).
|
||||
// A cancellation-SHAPED exception raised while our token is still live (a gateway's
|
||||
// own internal deadline, say) lands here deliberately: it is an ordinary write
|
||||
// failure, and exempting it would create a tag #538 can never quarantine.
|
||||
// failure, and exempting it would create a tag the failure budget can never quarantine.
|
||||
ok = false;
|
||||
}
|
||||
|
||||
@@ -778,7 +778,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
|
||||
// Fold the outcomes on the single logical drain flow — NEVER inside the parallel lambdas.
|
||||
// _tagWriteFailures is actor state (kept single-flight by _draining); mutating it from N
|
||||
// concurrent tasks would corrupt the Gitea #538 counters. Nothing below observes completion
|
||||
// concurrent tasks would corrupt the failure counters. Nothing below observes completion
|
||||
// ORDER, so the fold is deterministic whatever order the writes finished in.
|
||||
var succeeded = 0;
|
||||
var failedGroups = new List<(string Tag, int Count)>();
|
||||
@@ -812,7 +812,7 @@ public sealed class ContinuousHistorizationRecorder : ReceiveActor, IWithTimers
|
||||
return new DrainResult(false, 0, batch.Count);
|
||||
}
|
||||
|
||||
// Gitea #538: at least one tag wrote, so the backend IS reachable and a tag that keeps
|
||||
// At least one tag wrote, so the backend IS reachable and a tag that keeps
|
||||
// failing is poison — most often one whose historian tag was never provisioned (EnsureTags
|
||||
// fires only for newly-ADDED historized tags, so a renamed historianTagname is easy to hit).
|
||||
// Left blocking, it pins the FIFO head forever while every HEALTHY tag in the batch is
|
||||
|
||||
@@ -81,33 +81,33 @@ public sealed class ServerHistorianOptions
|
||||
/// cap). When a resume read stalls on such a cluster, the node manager over-fetches up to
|
||||
/// <c>MaxTieClusterOverfetch + 1</c> ties at that single timestamp (a <c>start == end</c> read) and
|
||||
/// pages through them; this bounds how large a single-timestamp burst the server will buffer in
|
||||
/// memory before it gives up and surfaces <c>BadTooManyOperations</c> for that node (#686; was
|
||||
/// memory before it gives up and surfaces <c>BadTooManyOperations</c> for that node (was
|
||||
/// <c>BadHistoryOperationUnsupported</c>). It is also the tie-cluster CEILING of a reverse read walked
|
||||
/// back from forward reads on a backend that cannot read newest-first (the Gateway; segments are sized from the page, #689): one timestamp holding
|
||||
/// back from forward reads on a backend that cannot read newest-first (the Gateway; segments are sized from the page): one timestamp holding
|
||||
/// more samples than this is refused <c>BadTooManyOperations</c>. The default (65536) comfortably covers
|
||||
/// any realistic same-millisecond burst; a value below 1 is treated as 1.
|
||||
/// </summary>
|
||||
public int MaxTieClusterOverfetch { get; init; } = 65536;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #691: whether HistoryRead-Raw honours <c>ReadRawModifiedDetails.ReturnBounds</c> (OPC UA Part 11 bounding
|
||||
/// values). Default <c>true</c>. <c>false</c> is the kill switch back to the pre-#691 answer: the flag is ignored
|
||||
/// whether HistoryRead-Raw honours <c>ReadRawModifiedDetails.ReturnBounds</c> (OPC UA Part 11 bounding
|
||||
/// values). Default <c>true</c>. <c>false</c> is the kill switch back to the previous answer: the flag is ignored
|
||||
/// (stored samples only) and a modified read carrying it is not refused <c>Bad_InvalidArgument</c>. Note the .NET
|
||||
/// SDK's <c>new ReadRawModifiedDetails()</c> defaults <c>ReturnBounds</c> (and <c>IsReadModified</c>) to <c>true</c>.
|
||||
/// </summary>
|
||||
public bool HonorReturnBounds { get; init; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #693, <c>Gateway</c> backend only: whether HistoryRead-AtTime is served from RAW gateway reads evaluated with
|
||||
/// <c>Gateway</c> backend only: whether HistoryRead-AtTime is served from RAW gateway reads evaluated with
|
||||
/// the SQL backends' shared AtTime rules (exact stored value at a stored time, linear between usable neighbours with
|
||||
/// the Interpolated bit, held before a Bad neighbour as Uncertain, null + the outage's Bad code inside an outage,
|
||||
/// <c>BadNoData</c> before the first sample). Default <c>true</c>. <c>false</c> is the kill switch back to the
|
||||
/// pre-#693 answer: AVEVA's own interpolation (the gateway's <c>ReadAtTime</c>), passed through unchanged.
|
||||
/// previous answer: AVEVA's own interpolation (the gateway's <c>ReadAtTime</c>), passed through unchanged.
|
||||
/// </summary>
|
||||
public bool GatewayAtTimeFromRaw { get; init; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #694 (opt-in): HistoryReadEvents never reads events older than <c>now − EventReadHorizon</c> — the earlier
|
||||
/// Opt-in: HistoryReadEvents never reads events older than <c>now − EventReadHorizon</c> — the earlier
|
||||
/// bound of every fresh events window is raised to it (both directions, every backend; a window wholly older is
|
||||
/// <c>GoodNoData</c>). Default <see cref="TimeSpan.Zero"/> = no horizon: every read is exact to its own window. It
|
||||
/// exists for the Gateway, where proving "no older events" costs a read down to the Unix epoch on
|
||||
@@ -145,7 +145,7 @@ public sealed class ServerHistorianOptions
|
||||
public TimeSpan HistoryReadDeadline { get; init; } = TimeSpan.FromSeconds(60);
|
||||
|
||||
/// <summary>
|
||||
/// <c>SqlServer</c> / <c>QuestDb</c> backends only (#671): the most raw in-window samples one Part 13
|
||||
/// <c>SqlServer</c> / <c>QuestDb</c> backends only: the most raw in-window samples one Part 13
|
||||
/// time-weighted read (TimeAverage, TimeAverage2, Total, Total2, Interpolative) may stream into the server-side
|
||||
/// evaluator — that family is not pushed down to SQL. A read past the cap stops at cap + 1 rows and fails THAT
|
||||
/// node with <c>BadTooManyOperations</c> instead of holding a pooled connection until
|
||||
@@ -155,7 +155,7 @@ public sealed class ServerHistorianOptions
|
||||
public int MaxTimeWeightedRawRows { get; init; } = 1_000_000;
|
||||
|
||||
/// <summary>
|
||||
/// Gitea #674: how far into the future an OPC UA HistoryUpdate (Insert / Replace / Update) item's
|
||||
/// how far into the future an OPC UA HistoryUpdate (Insert / Replace / Update) item's
|
||||
/// <c>SourceTimestamp</c> may lie, measured from the server clock. An item beyond <c>now + skew</c> is refused
|
||||
/// <c>BadOutOfRange</c> by the node manager before any backend sees it — a far-future row is never a legitimate
|
||||
/// history edit, and on a backend that judges retention against the newest timestamp it could age out every
|
||||
|
||||
Reference in New Issue
Block a user