docs(comments): strip internal task/milestone/bundle bookkeeping from code comments
Remove project bookkeeping citations from shipped code comments across the solution: hyphenated task IDs (WP-14, StoreAndForward-025), milestone/task/ issue refs (M3, Task 4, Audit Log #23, #21), Bundle X task-bundle labels, and C/D/K/S/T phase labels. Comment text only — no code logic, string/log literals, or XML-doc structure changed. Genuine descriptions are preserved (only the citation is stripped), and technical lookalikes are retained (UTF-8, SHA-256, T00:00:00, M365, UTC-5, pre-C4/pre-C5 schema versions). Flagged by the new CommentChecker TaskReferenceInComment / TrackingReferenceInComment checks plus targeted grep passes; full solution builds clean, append-only guard tests pass.
This commit is contained in:
@@ -10,7 +10,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// byte-deterministic output (System.Text.Json respects declared order).
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// C1 of the ScadaBridge audit re-architecture (Task 2.5). Pure types only.
|
||||
/// Pure types only.
|
||||
/// </remarks>
|
||||
public sealed record AuditDetails
|
||||
{
|
||||
|
||||
@@ -26,7 +26,6 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// System.Text.Json honours declared order, so serialization is stable across calls.</item>
|
||||
/// </list>
|
||||
/// </para>
|
||||
/// <para>C1 of the ScadaBridge audit re-architecture (Task 2.5).</para>
|
||||
/// </remarks>
|
||||
public static class AuditDetailsCodec
|
||||
{
|
||||
|
||||
@@ -15,7 +15,6 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// that maps onto the canonical <c>Category</c> field.</item>
|
||||
/// </list>
|
||||
/// </para>
|
||||
/// <para>C1 of the ScadaBridge audit re-architecture (Task 2.5).</para>
|
||||
/// </remarks>
|
||||
public static class AuditFieldBuilders
|
||||
{
|
||||
|
||||
@@ -18,7 +18,6 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// <item>All other statuses (<c>Submitted</c>, <c>Forwarded</c>, <c>Attempted</c>,
|
||||
/// <c>Skipped</c>) → <see cref="AuditOutcome.Success"/>.</item>
|
||||
/// </list>
|
||||
/// <para>C1 of the ScadaBridge audit re-architecture (Task 2.5).</para>
|
||||
/// </remarks>
|
||||
public static class AuditOutcomeProjector
|
||||
{
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
|
||||
/// <summary>
|
||||
/// Transitional canonical ⇄ 24-column shim for the two AuditLog storage
|
||||
/// implementations (site SQLite, central SQL Server). C3 keeps the existing
|
||||
/// implementations (site SQLite, central SQL Server). Keeps the existing
|
||||
/// 24-column tables UNCHANGED; this helper decomposes a canonical
|
||||
/// <see cref="ZB.MOM.WW.Audit.AuditEvent"/> into the typed domain values the
|
||||
/// columns expect (Channel/Kind/Status enums + the <see cref="AuditDetails"/>
|
||||
@@ -13,12 +13,11 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// C3 of the ScadaBridge audit re-architecture (Task 2.5). The canonical record
|
||||
/// The canonical record
|
||||
/// only carries Action/Category/Outcome at the top level and stashes every
|
||||
/// ScadaBridge domain field inside <c>DetailsJson</c>; the legacy storage rows
|
||||
/// carry the domain fields as typed columns. This shim bridges the two without
|
||||
/// any schema change. C4 replaces the site shim with the real DetailsJson
|
||||
/// schema; C5 the central one.
|
||||
/// any schema change.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// <c>ForwardState</c> is deliberately NOT part of this projection — it is a
|
||||
@@ -163,7 +162,7 @@ public static class AuditRowProjection
|
||||
/// <summary>
|
||||
/// Returns a copy of <paramref name="evt"/> with the central-side ingest timestamp
|
||||
/// stamped into its <c>DetailsJson</c> (<see cref="AuditDetails.IngestedAtUtc"/>).
|
||||
/// C3 transitional shim: <c>IngestedAtUtc</c> is a DetailsJson field on the canonical
|
||||
/// <c>IngestedAtUtc</c> is a DetailsJson field on the canonical
|
||||
/// record, so the central ingest paths stamp it here rather than on a top-level
|
||||
/// property as the legacy bespoke record allowed.
|
||||
/// </summary>
|
||||
|
||||
@@ -12,11 +12,11 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
/// identically everywhere — no per-site drift.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>C3 of the ScadaBridge audit re-architecture (Task 2.5). The canonical
|
||||
/// <para>The canonical
|
||||
/// record is the type at every seam, emit site, DTO boundary, and redactor; the
|
||||
/// ScadaBridge domain fields ride in <c>DetailsJson</c> via
|
||||
/// <see cref="AuditDetailsCodec"/>.</para>
|
||||
/// <para>Mapping (see Task 2.5 spec):
|
||||
/// <para>Mapping:
|
||||
/// <list type="bullet">
|
||||
/// <item><c>Action</c> = <see cref="AuditFieldBuilders.BuildAction"/>(channel, kind).</item>
|
||||
/// <item><c>Category</c> = <see cref="AuditFieldBuilders.BuildCategory"/>(channel) (= channel name).</item>
|
||||
|
||||
@@ -2,7 +2,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Audit;
|
||||
|
||||
/// <summary>
|
||||
/// Point-in-time operational metrics for the central <c>SiteCalls</c> table
|
||||
/// (Site Call Audit #22), surfaced on the health dashboard. The cached-call
|
||||
/// surfaced on the health dashboard. The cached-call
|
||||
/// counterpart of <see cref="ZB.MOM.WW.ScadaBridge.Commons.Types.Notifications.NotificationKpiSnapshot"/>;
|
||||
/// mirrors its shape so the Central UI Site Calls KPI tiles can reuse the
|
||||
/// Notification Outbox tile layout.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
|
||||
/// <summary>
|
||||
/// Audit Log (#23) M7 Bundle E (T13) — point-in-time KPI snapshot for the central
|
||||
/// Point-in-time KPI snapshot for the central
|
||||
/// Health dashboard's "Audit" tile group. Aggregates volume + error counts over
|
||||
/// the trailing window from the central <c>AuditLog</c> table and combines them
|
||||
/// with the global pending backlog summed across every site's
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// Top-level Audit Log (#23) channel — the trust boundary the audited action crosses.
|
||||
/// Top-level Audit Log channel — the trust boundary the audited action crosses.
|
||||
/// One of: outbound API call, outbound DB write, notification send/deliver, inbound API request,
|
||||
/// or a two-person ("secured") write through its submit/approve/reject/execute lifecycle.
|
||||
/// </summary>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// Site-local Audit Log (#23) forwarding state, tracked only in the site SQLite hot-path.
|
||||
/// Site-local Audit Log forwarding state, tracked only in the site SQLite hot-path.
|
||||
/// Central rows leave this null. <c>Pending</c> = not yet sent; <c>Forwarded</c> = telemetry sent
|
||||
/// and acked; <c>Reconciled</c> = confirmed present centrally via the periodic pull fallback.
|
||||
/// The site retention purge MUST NOT drop a row whose state is still <c>Pending</c>.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// Specific Audit Log (#23) event kind within a channel — what action produced the row.
|
||||
/// Specific Audit Log event kind within a channel — what action produced the row.
|
||||
/// Cached variants emit multiple rows per operation (submit → forward → attempt → resolve).
|
||||
/// The <c>SecuredWrite*</c> kinds emit one row per two-person-write lifecycle event
|
||||
/// (submit → approve → execute, or submit → reject).
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// Lifecycle status of an Audit Log (#23) event row.
|
||||
/// Lifecycle status of an Audit Log event row.
|
||||
/// Cached operations produce multiple rows tracking <c>Submitted → Forwarded → Attempted → Delivered/Parked/Discarded</c>.
|
||||
/// <c>Skipped</c> is used when an action was short-circuited (e.g. dry-run) but should still be audited.
|
||||
/// </summary>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// WP-9: Categories for store-and-forward messages.
|
||||
/// Categories for store-and-forward messages.
|
||||
/// </summary>
|
||||
public enum StoreAndForwardCategory
|
||||
{
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Enums;
|
||||
|
||||
/// <summary>
|
||||
/// WP-9: Status of a store-and-forward message.
|
||||
/// Status of a store-and-forward message.
|
||||
/// </summary>
|
||||
public enum StoreAndForwardMessageStatus
|
||||
{
|
||||
|
||||
@@ -25,7 +25,7 @@ public sealed record ConfigurationDiff
|
||||
/// <summary>
|
||||
/// Diff entries for connection configurations, keyed by connection name.
|
||||
/// Surfaces standalone endpoint/protocol/failover drift that does not show
|
||||
/// up as a per-attribute binding change (TemplateEngine-018).
|
||||
/// up as a per-attribute binding change.
|
||||
/// </summary>
|
||||
public IReadOnlyList<DiffEntry<ConnectionConfig>> ConnectionChanges { get; init; } = [];
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ public sealed record ValidationResult
|
||||
|
||||
/// <summary>
|
||||
/// Produces a compact, human-readable summary of the validation errors instead of a
|
||||
/// flat semicolon-joined dump (followup #8). The old behaviour concatenated one clause
|
||||
/// flat semicolon-joined dump. The old behaviour concatenated one clause
|
||||
/// per error — for an instance with 50–194 unbound attributes that is a wall of text
|
||||
/// unreadable in a CLI/UI toast. This groups errors by <see cref="ValidationCategory"/>
|
||||
/// and, within a category, rolls entries up by "module" (the entity's canonical name up
|
||||
@@ -183,7 +183,7 @@ public enum ValidationCategory
|
||||
NativeAlarmSourceInvalid,
|
||||
|
||||
/// <summary>
|
||||
/// M9-T32b: a script/method parameter or return JSON Schema contains a
|
||||
/// A script/method parameter or return JSON Schema contains a
|
||||
/// <c>{"$ref":"lib:Name"}</c> reference that could not be resolved against the
|
||||
/// shared-schema library — dangling, cyclic, or over-depth. Deploy-blocking.
|
||||
/// </summary>
|
||||
|
||||
@@ -64,7 +64,7 @@ public sealed class InboundApiSchema
|
||||
|
||||
/// <summary>
|
||||
/// Parses a stored definition string into an <see cref="InboundApiSchema"/>,
|
||||
/// resolving any <c>{"$ref":"lib:Name"}</c> library references (M9-T32b) through
|
||||
/// resolving any <c>{"$ref":"lib:Name"}</c> library references through
|
||||
/// the caller-supplied <paramref name="resolveRef"/> seam.
|
||||
///
|
||||
/// <para>
|
||||
@@ -117,7 +117,7 @@ public sealed class InboundApiSchema
|
||||
/// Parses a stored definition string into an <see cref="InboundApiSchema"/>,
|
||||
/// resolving <c>{"$ref":"lib:Name"}</c> library references through the
|
||||
/// caller-supplied <paramref name="resolveRef"/> seam, and COLLECTING (rather than
|
||||
/// throwing on) any references that cannot be resolved (M9-T32b).
|
||||
/// throwing on) any references that cannot be resolved.
|
||||
///
|
||||
/// <para>
|
||||
/// This is the deploy-time entry point: a dangling, cyclic, or over-depth
|
||||
@@ -176,7 +176,7 @@ public sealed class InboundApiSchema
|
||||
throw new JsonException($"Schema nesting exceeds the maximum allowed depth of {MaxDepth}.");
|
||||
}
|
||||
|
||||
// $ref resolution (M9-T32b): a {"$ref":"lib:Name"} node is replaced by the
|
||||
// $ref resolution: a {"$ref":"lib:Name"} node is replaced by the
|
||||
// referenced schema, resolved through the caller-supplied seam. Dangling,
|
||||
// cyclic, and over-depth refs are recorded as unresolved (the caller decides
|
||||
// whether to throw or collect) and parse continues with a shape-only schema.
|
||||
@@ -243,7 +243,7 @@ public sealed class InboundApiSchema
|
||||
private const string UnresolvedRefType = "ref";
|
||||
|
||||
/// <summary>
|
||||
/// M9-T32b — cheap pre-flight check: does this definition JSON contain ANY
|
||||
/// Cheap pre-flight check: does this definition JSON contain ANY
|
||||
/// <c>$ref</c> token at all? Lets a caller (e.g. the InboundAPI runtime path) skip the
|
||||
/// shared-schema library pre-load entirely when a schema uses no references — so a
|
||||
/// <c>$ref</c>-free method pays NO extra cost beyond today. The check is intentionally
|
||||
@@ -532,7 +532,7 @@ public sealed class InboundApiSchema
|
||||
return;
|
||||
}
|
||||
|
||||
// Reject undeclared fields (defensive, consistent with InboundAPI-010's
|
||||
// Reject undeclared fields (defensive, consistent with the
|
||||
// top-level "unexpected parameter" rejection) — a typo'd nested field is
|
||||
// surfaced instead of silently ignored. Skipped when no fields are
|
||||
// declared (a bare {"type":"object"} stays shape-only, like the legacy
|
||||
@@ -609,7 +609,7 @@ public sealed record InboundApiSchemaField(string Name, bool Required, InboundAp
|
||||
|
||||
/// <summary>
|
||||
/// A single <c>{"$ref":"lib:Name"}</c> reference that could NOT be resolved during
|
||||
/// <see cref="InboundApiSchema.ParseWithRefs"/> (M9-T32b). The reference <see cref="Name"/>
|
||||
/// <see cref="InboundApiSchema.ParseWithRefs"/>. The reference <see cref="Name"/>
|
||||
/// is kept SEPARATE from the diagnostic <see cref="Reason"/> so a message can render the
|
||||
/// pointer cleanly (e.g. <c>schema 'lib:Foo' could not be resolved (cyclic reference)</c>)
|
||||
/// rather than embedding the annotation inside the <c>lib:</c>-looking string.
|
||||
@@ -643,7 +643,7 @@ public sealed record UnresolvedSchemaRef(string Name, string? Reason)
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The outcome of <see cref="InboundApiSchema.ParseWithRefs"/> (M9-T32b): the parsed
|
||||
/// The outcome of <see cref="InboundApiSchema.ParseWithRefs"/>: the parsed
|
||||
/// schema (with <c>{"$ref":"lib:Name"}</c> references resolved where possible) plus the
|
||||
/// references that could NOT be resolved — dangling (the seam returned <c>null</c> or no
|
||||
/// seam was supplied), cyclic, or over-depth. A non-empty <see cref="UnresolvedReferences"/>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
|
||||
/// <summary>
|
||||
/// Canonical <em>charted</em> KPI metric-name identifiers (M6 "KPI History &
|
||||
/// Canonical <em>charted</em> KPI metric-name identifiers ("KPI History &
|
||||
/// Trends") — the value of <see cref="ZB.MOM.WW.ScadaBridge.Commons.Entities.Kpi.KpiSample.Metric"/>
|
||||
/// for every metric a Central UI trend chart renders. Each owning
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Interfaces.Kpi.IKpiSampleSource"/> emits
|
||||
@@ -30,7 +30,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
public static class KpiMetrics
|
||||
{
|
||||
/// <summary>
|
||||
/// Charted Notification Outbox (#21) metrics — <see cref="KpiSources.NotificationOutbox"/>.
|
||||
/// Charted Notification Outbox metrics — <see cref="KpiSources.NotificationOutbox"/>.
|
||||
/// Rendered by the Central UI Notification Outbox KPIs trend panel.
|
||||
/// </summary>
|
||||
public static class NotificationOutbox
|
||||
@@ -46,7 +46,7 @@ public static class KpiMetrics
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Charted Site Call Audit (#22) metrics — <see cref="KpiSources.SiteCallAudit"/>.
|
||||
/// Charted Site Call Audit metrics — <see cref="KpiSources.SiteCallAudit"/>.
|
||||
/// Rendered by the Central UI Site Calls report trend panel.
|
||||
/// </summary>
|
||||
public static class SiteCallAudit
|
||||
@@ -62,7 +62,7 @@ public static class KpiMetrics
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Charted Audit Log (#23) metrics — <see cref="KpiSources.AuditLog"/>.
|
||||
/// Charted Audit Log metrics — <see cref="KpiSources.AuditLog"/>.
|
||||
/// Rendered by the Central UI Audit Log page trend panel.
|
||||
/// </summary>
|
||||
public static class AuditLog
|
||||
@@ -78,7 +78,7 @@ public static class KpiMetrics
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Charted Site Health (#11) metrics — <see cref="KpiSources.SiteHealth"/>.
|
||||
/// Charted Site Health metrics — <see cref="KpiSources.SiteHealth"/>.
|
||||
/// Rendered by the Central UI Health-dashboard per-site trend panel.
|
||||
/// </summary>
|
||||
public static class SiteHealth
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
|
||||
/// <summary>
|
||||
/// Canonical KPI scope discriminators (M6 "KPI History & Trends") — the value of
|
||||
/// Canonical KPI scope discriminators ("KPI History & Trends") — the value of
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Entities.Kpi.KpiSample.Scope"/>. Each
|
||||
/// constant's value equals its name. The companion
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Entities.Kpi.KpiSample.ScopeKey"/> qualifies
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
|
||||
/// <summary>
|
||||
/// Pure, deterministic downsampling helper for KPI series charting (M6 "KPI History & Trends").
|
||||
/// Pure, deterministic downsampling helper for KPI series charting ("KPI History & Trends").
|
||||
/// Reduces a raw <see cref="KpiSeriesPoint"/> series to at most <c>maxPoints</c> points using
|
||||
/// last-value-per-bucket / gauge semantics — suitable for step/area charts where the most
|
||||
/// recent value in a window best represents that window.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
|
||||
/// <summary>
|
||||
/// A single bucketed point of a KPI series (M6 "KPI History & Trends") — the
|
||||
/// A single bucketed point of a KPI series ("KPI History & Trends") — the
|
||||
/// aggregated value of one series over the bucket starting at
|
||||
/// <see cref="BucketStartUtc"/>. Returned by the bucketed query path and the
|
||||
/// reusable trend chart.
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Kpi;
|
||||
|
||||
/// <summary>
|
||||
/// Canonical KPI source identifiers (M6 "KPI History & Trends") — the value of
|
||||
/// Canonical KPI source identifiers ("KPI History & Trends") — the value of
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Entities.Kpi.KpiSample.Source"/> and the
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Interfaces.Kpi.IKpiSampleSource.Source"/>
|
||||
/// each owning component reports. Each constant's value equals its name.
|
||||
/// </summary>
|
||||
public static class KpiSources
|
||||
{
|
||||
/// <summary>Notification Outbox (#21) delivery KPIs.</summary>
|
||||
/// <summary>Notification Outbox delivery KPIs.</summary>
|
||||
public const string NotificationOutbox = "NotificationOutbox";
|
||||
|
||||
/// <summary>Site Call Audit (#22) cached-call KPIs.</summary>
|
||||
/// <summary>Site Call Audit cached-call KPIs.</summary>
|
||||
public const string SiteCallAudit = "SiteCallAudit";
|
||||
|
||||
/// <summary>Audit Log (#23) ingest / backlog KPIs.</summary>
|
||||
/// <summary>Audit Log ingest / backlog KPIs.</summary>
|
||||
public const string AuditLog = "AuditLog";
|
||||
|
||||
/// <summary>Site Health (#11) monitoring KPIs.</summary>
|
||||
/// <summary>Site Health monitoring KPIs.</summary>
|
||||
public const string SiteHealth = "SiteHealth";
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ public class ScriptParameters : IReadOnlyDictionary<string, object?>
|
||||
// that cannot be converted is a caller/script bug, not "not supplied":
|
||||
// throw with a descriptive message rather than silently returning null
|
||||
// (which a script would misread as absent). This mirrors Get<T>() and the
|
||||
// array/list element paths. See Commons-003.
|
||||
// array/list element paths.
|
||||
var converted = ConvertScalar(value, underlyingType, key);
|
||||
return (T)converted;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
|
||||
/// <summary>
|
||||
/// Audit Log (#23) M6 Bundle E (T6) — point-in-time snapshot of the site-local
|
||||
/// Point-in-time snapshot of the site-local
|
||||
/// SQLite audit-log queue health, surfaced on
|
||||
/// <see cref="ZB.MOM.WW.ScadaBridge.Commons.Messages.Health.SiteHealthReport"/> as
|
||||
/// <c>SiteAuditBacklog</c> and refreshed periodically by the
|
||||
|
||||
@@ -2,7 +2,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
|
||||
/// <summary>
|
||||
/// Operational state of one cached call as seen by the site, carried on the
|
||||
/// combined <c>CachedCallTelemetry</c> packet (Audit Log #23 / M3) and persisted
|
||||
/// combined <c>CachedCallTelemetry</c> packet and persisted
|
||||
/// at central as the <c>SiteCalls</c> row mirroring the call's status.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
|
||||
@@ -3,7 +3,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
/// <summary>
|
||||
/// Strongly-typed identifier for a cached outbound operation
|
||||
/// (<c>ExternalSystem.CachedCall</c> / <c>Database.CachedWrite</c>) — the unified
|
||||
/// tracking handle introduced by Audit Log #23 (M3). The same id is the
|
||||
/// tracking handle introduced by Audit Log. The same id is the
|
||||
/// idempotency key end-to-end: it is stamped on every <c>AuditLog</c> row
|
||||
/// produced for the operation's lifecycle (CachedSubmit → ApiCallCached /
|
||||
/// DbWriteCached × N attempts → CachedResolve) and is the PK on the central
|
||||
|
||||
@@ -2,7 +2,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
|
||||
/// <summary>
|
||||
/// Site-local snapshot of a cached operation's tracking state, returned by the
|
||||
/// <c>Tracking.Status(TrackedOperationId)</c> script API (Audit Log #23 / M3).
|
||||
/// <c>Tracking.Status(TrackedOperationId)</c> script API.
|
||||
/// </summary>
|
||||
/// <param name="Id">Tracking handle returned by <c>CachedCall</c>/<c>CachedWrite</c>.</param>
|
||||
/// <param name="Kind">
|
||||
@@ -29,7 +29,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types;
|
||||
/// Cluster node that submitted the cached call (e.g. <c>"node-a"</c> /
|
||||
/// <c>"node-b"</c>), captured at enqueue time. Null on rows persisted before
|
||||
/// the SourceNode stamping migration; stamping itself is wired in a later task.
|
||||
/// Commons-023: trailing-optional with a <c>= null</c> default, matching the
|
||||
/// Trailing-optional with a <c>= null</c> default, matching the
|
||||
/// SourceNode rollout convention now used on <c>SiteCallSummary</c>,
|
||||
/// <c>SiteCallDetail</c>, <c>NotificationSummary</c> and <c>NotificationDetail</c>
|
||||
/// — so existing positional construction sites keep compiling as new
|
||||
|
||||
@@ -16,7 +16,7 @@ public enum MappingAction
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Resolves one site referenced by an incoming bundle (M8 site/instance-scoped
|
||||
/// Resolves one site referenced by an incoming bundle (site/instance-scoped
|
||||
/// transport). <paramref name="TargetSiteIdentifier"/> is required when
|
||||
/// <paramref name="Action"/> is <see cref="MappingAction.MapToExisting"/> and null
|
||||
/// when it is <see cref="MappingAction.CreateNew"/>.
|
||||
|
||||
@@ -3,7 +3,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Transport;
|
||||
public sealed class BundleSession
|
||||
{
|
||||
/// <summary>
|
||||
/// Commons-016: legacy per-session lockout threshold (kept on this type for the
|
||||
/// Legacy per-session lockout threshold (kept on this type for the
|
||||
/// shim <see cref="Locked"/> getter). The authoritative, server-side per-bundle
|
||||
/// counter is bounded by <c>TransportOptions.MaxUnlockAttemptsPerSession</c>
|
||||
/// (default also <c>3</c>) and is what <c>BundleImporter.LoadAsync</c> consults.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Transport;
|
||||
|
||||
// ApiKeys is intentionally absent: inbound API keys are not transported between
|
||||
// environments (re-arch C4). Only API methods are summarised.
|
||||
// environments. Only API methods are summarised.
|
||||
public sealed record BundleSummary(
|
||||
int Templates,
|
||||
int TemplateFolders,
|
||||
@@ -11,12 +11,12 @@ public sealed record BundleSummary(
|
||||
int NotificationLists,
|
||||
int SmtpConfigs,
|
||||
int ApiMethods,
|
||||
// Additive (M8 A1): site/instance-scoped artifacts. Defaulted to 0 so manifests
|
||||
// Additive: site/instance-scoped artifacts. Defaulted to 0 so manifests
|
||||
// written by older exporters (which omit these JSON properties) deserialize fine.
|
||||
int Sites = 0,
|
||||
int DataConnections = 0,
|
||||
int Instances = 0,
|
||||
// Additive (S10b): SMS provider config count, mirroring SmtpConfigs. Defaulted to
|
||||
// Additive: SMS provider config count, mirroring SmtpConfigs. Defaulted to
|
||||
// 0 so manifests written by older exporters (which omit this JSON property)
|
||||
// deserialize fine.
|
||||
int SmsConfigs = 0);
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Transport;
|
||||
/// the bundle manifest (plaintext) so the importer can derive the per-bundle key and
|
||||
/// initialise the cipher without prior knowledge of the passphrase.
|
||||
/// <para>
|
||||
/// Commons-015: invariants are enforced in the constructor so a malformed envelope
|
||||
/// Invariants are enforced in the constructor so a malformed envelope
|
||||
/// (unknown algorithm, unsupported KDF, weak iteration count, null salt/IV) is
|
||||
/// rejected at the type boundary rather than failing inside
|
||||
/// <see cref="System.Security.Cryptography.AesGcm"/> with a misleading exception.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.Commons.Types.Transport;
|
||||
|
||||
// Inbound API keys are intentionally absent from the transport selection: per the
|
||||
// inbound-API-key re-architecture (commit C4) keys are NOT carried between
|
||||
// inbound-API-key re-architecture, keys are NOT carried between
|
||||
// environments. They live in the per-environment SQLite store (per-env pepper +
|
||||
// secret-shown-once) and are re-created/re-granted via the admin UI/CLI on the
|
||||
// destination. Only API *methods* travel in a bundle.
|
||||
@@ -14,21 +14,21 @@ public sealed record ExportSelection(
|
||||
IReadOnlyList<int> SmtpConfigurationIds,
|
||||
IReadOnlyList<int> ApiMethodIds,
|
||||
bool IncludeDependencies,
|
||||
// Additive (M8 A1): site/instance-scoped export. Defaulted to empty so every
|
||||
// Additive: site/instance-scoped export. Defaulted to empty so every
|
||||
// existing positional caller keeps compiling; older callers select no sites/instances.
|
||||
IReadOnlyList<int>? SiteIds = null,
|
||||
IReadOnlyList<int>? InstanceIds = null,
|
||||
// Additive (S10b): SMS provider config export, mirroring SmtpConfigurationIds.
|
||||
// Additive: SMS provider config export, mirroring SmtpConfigurationIds.
|
||||
// Defaulted null (trailing) so every existing positional caller keeps compiling;
|
||||
// older callers select no SMS configs.
|
||||
IReadOnlyList<int>? SmsConfigurationIds = null)
|
||||
{
|
||||
/// <summary>Sites selected for site/instance-scoped export (M8). Never null.</summary>
|
||||
/// <summary>Sites selected for site/instance-scoped export. Never null.</summary>
|
||||
public IReadOnlyList<int> SiteIds { get; init; } = SiteIds ?? Array.Empty<int>();
|
||||
|
||||
/// <summary>Instances selected for site/instance-scoped export (M8). Never null.</summary>
|
||||
/// <summary>Instances selected for site/instance-scoped export. Never null.</summary>
|
||||
public IReadOnlyList<int> InstanceIds { get; init; } = InstanceIds ?? Array.Empty<int>();
|
||||
|
||||
/// <summary>SMS provider configurations selected for export (S10b). Never null.</summary>
|
||||
/// <summary>SMS provider configurations selected for export. Never null.</summary>
|
||||
public IReadOnlyList<int> SmsConfigurationIds { get; init; } = SmsConfigurationIds ?? Array.Empty<int>();
|
||||
}
|
||||
|
||||
@@ -12,8 +12,8 @@ public sealed record ImportPreviewItem(
|
||||
string? BlockerReason);
|
||||
|
||||
/// <summary>
|
||||
/// A site reference in an incoming bundle that the operator must resolve before import
|
||||
/// (M8 A1). <paramref name="AutoMatchTargetIdentifier"/> is the destination site the
|
||||
/// A site reference in an incoming bundle that the operator must resolve before import.
|
||||
/// <paramref name="AutoMatchTargetIdentifier"/> is the destination site the
|
||||
/// importer auto-matched by identifier, or null when no match was found.
|
||||
/// </summary>
|
||||
public sealed record RequiredSiteMapping(
|
||||
@@ -23,7 +23,7 @@ public sealed record RequiredSiteMapping(
|
||||
|
||||
/// <summary>
|
||||
/// A connection reference (scoped to a source site) in an incoming bundle that the
|
||||
/// operator must resolve before import (M8 A1). <paramref name="AutoMatchTargetName"/>
|
||||
/// operator must resolve before import. <paramref name="AutoMatchTargetName"/>
|
||||
/// is the destination connection the importer auto-matched by name, or null when no
|
||||
/// match was found.
|
||||
/// </summary>
|
||||
@@ -35,16 +35,16 @@ public sealed record RequiredConnectionMapping(
|
||||
public sealed record ImportPreview(
|
||||
Guid SessionId,
|
||||
IReadOnlyList<ImportPreviewItem> Items,
|
||||
// Additive (M8 A1): site/connection references the operator must resolve before
|
||||
// Additive: site/connection references the operator must resolve before
|
||||
// applying. Defaulted to empty so every existing positional caller keeps compiling.
|
||||
IReadOnlyList<RequiredSiteMapping>? RequiredSiteMappings = null,
|
||||
IReadOnlyList<RequiredConnectionMapping>? RequiredConnectionMappings = null)
|
||||
{
|
||||
/// <summary>Site references the operator must resolve before import (M8). Never null.</summary>
|
||||
/// <summary>Site references the operator must resolve before import. Never null.</summary>
|
||||
public IReadOnlyList<RequiredSiteMapping> RequiredSiteMappings { get; init; } =
|
||||
RequiredSiteMappings ?? Array.Empty<RequiredSiteMapping>();
|
||||
|
||||
/// <summary>Connection references the operator must resolve before import (M8). Never null.</summary>
|
||||
/// <summary>Connection references the operator must resolve before import. Never null.</summary>
|
||||
public IReadOnlyList<RequiredConnectionMapping> RequiredConnectionMappings { get; init; } =
|
||||
RequiredConnectionMappings ?? Array.Empty<RequiredConnectionMapping>();
|
||||
}
|
||||
|
||||
@@ -9,6 +9,6 @@ public sealed record ImportResult(
|
||||
IReadOnlyList<int> StaleInstanceIds,
|
||||
string AuditEventCorrelation,
|
||||
// Number of legacy inbound API keys found in the bundle that were ignored
|
||||
// (re-arch C4 — keys are not transported; re-create them on this environment).
|
||||
// (keys are not transported; re-create them on this environment).
|
||||
// Defaults to 0 so existing positional construction sites stay source-compatible.
|
||||
int ApiKeysIgnored = 0);
|
||||
|
||||
Reference in New Issue
Block a user