Commit Graph

5298 Commits

Author SHA1 Message Date
Joseph Doherty 4c8539b897 fix(grpc-data): A1 review round 2 F4 — a Galaxy sentinel signals only a stream opened under the live subscription
The feed raises a new IGalaxyAlarmFeed.StreamOpened (default no-op accessors) before each stream's first message;
GalaxyDriver records the live subscription then, and its sentinel signals only if that is still the live one —
so refs whose snapshot entries arrived before (or without) the subscription are never signalled. The handle is
now added before the feed starts, so the first stream opens under it.
2026-11-24 11:30:30 -05:00
Joseph Doherty ea19c3ed4f fix(grpc-data): A1 review round 2 F3 — an MTConnect delta signals the conditions it touched
A condition Unavailable at baseline never became known: its later Normal is a quality-only emission and only full
emissions signalled. A delta emission now signals its touched conditions whose level is not Unavailable, after the
events and under the same lock (tracker baseline required). Sample_delta_does_not_signal… (which pinned the old
behaviour) is now Sample_delta_signals_its_touched_conditions_and_a_rebaseline_signals_all.
2026-11-24 11:28:14 -05:00
Joseph Doherty 4d21ccafa1 fix(grpc-data): A1 review round 2 F1 + F2 — an ack-revert establishes nothing; every Good edge withdraws; Bad edge forgets unsignalable
F1: RevertNativeAlarmAck projected through WriteAlarmCondition, which re-marked a comms-withdrawn native condition
known; with the Good edge's conditional withdrawal skipped (GoodSinceUtc null) it read known-inactive-Good until the
replay. AlarmStateUpdate.EstablishesState (false for the revert) rides a new default sink overload
WriteAlarmCondition(..., establishesState) through the deferred and SDK sinks to the node manager, and every Good
edge now withdraws unconditionally.
F2: the Bad edge clears the unsignalable set, so a stale report cannot arm the backstop on the next Good edge.
The rig's CollectAlarmTraffic skips withdrawals (every edge now sends one).
2026-11-24 11:26:56 -05:00
Joseph Doherty 7489456843 test(grpc-data): A1 real-driver test fishes the known mark, not a withdrawal 2026-11-24 11:03:52 -05:00
Joseph Doherty 27a59716aa Merge A1 review round 1 fixes 2026-11-24 11:03:44 -05:00
Joseph Doherty 2d7f67de72 docs(grpc-data): A1 review round 1 — findings, resolutions, mutations and gates 2026-11-24 11:03:09 -05:00
Joseph Doherty 795ad6ccc7 fix(grpc-data): A1 review S2 — only a retired child's Bad edge withdraws known; a stray sender changes nothing 2026-11-24 10:47:49 -05:00
Joseph Doherty c033abd54f docs(grpc-data): A1 drivers gates 2026-11-24 10:46:59 -05:00
Joseph Doherty 2fdf9d87c2 fix(grpc-data): A1 review nit — colliding condition placements are logged at Warning (locally)
DistinctPlacements still drops every placement of an address claimed twice (fail closed); Compile takes an
optional logger (the coordinator passes its own) and the drop is reported in the local log only.
2026-11-24 10:44:00 -05:00
Joseph Doherty 16166c21e5 fix(grpc-data): A1 review S3 + S4 + nits — snapshot start cursor, readiness cut with the snapshot, failed applies
- S3a: SnapshotConditions reads a start cursor under Lock before enumerating keys; every slice carries it, so a
  condition materialised and activated between the enumeration and slice 1's hold is covered by deltas after it.
- S3b: each hold captures the apply generation (bumped when a rebuild begins) and the complete flag; slices carry
  them and ConditionSnapshotSlice.IsCompleteSnapshot / ConditionStateHub.IsSnapshotCompleteFor detect a rebuild
  that straddles a multi-slice snapshot. An empty scope still takes one hold.
- S3c: maxConditionsPerHold is clamped to MaxConditionsPerHoldLimit (5,000).
- S4: CompleteAddressSpaceApply(bool succeeded) (new default sink member, forwarded by the deferred and SDK sinks);
  the publish actor passes !Degraded. A failed/degraded rebuild keeps readiness false and its pending removals,
  emitting no removal records; the next successful apply completes it.
- Nits: ConditionStateRecord.UnshelveTimeUtc (timed-shelve expiry); ConditionStateHub.Read has a bounded default.
2026-11-24 10:43:04 -05:00
Joseph Doherty df6fb8ff5e docs(grpc-data): A1-core — drivers section (hooks, tests, mutations, L4, deviations) 2026-11-24 10:37:06 -05:00
Joseph Doherty 6c94a2ec0e test(grpc-data): rig dev literal DataConnections__ConditionKeySecret on both source services 2026-11-24 10:37:02 -05:00
Joseph Doherty 3b242f5839 docs(grpc-data): plan §5.2 condition_key formula matches ConditionKeys.Derive (realm byte, upper-cased cluster) + golden-vector test 2026-11-24 10:37:02 -05:00
Joseph Doherty f08ca7d9e3 fix(grpc-data): A1 review S2 + F5 re-arm + nits — native known is withdrawn on comms loss
- The Bad connectivity edge (and a Good edge with no Bad edge since the last Good one, or from a new child
  incarnation) sends MarkConditionsKnown(Known: false) for the driver's condition nodes, ahead of the quality
  annotation, so an alarm raised during an outage never reads known-inactive, Good after the reconnect. Stopping a
  child (a respawn) withdraws too.
- DriverInstanceActor stamps a connection epoch (bumped on every Connected entry) on the initial-state signal and
  on ConnectivityChanged(Connected); a signal raised under an earlier connection is dropped by the child and the host.
- G3 never discards a deferred withdrawal.
- F5 'still unknown' follows the node manager: a native transition takes its ref out of Pending.
- Re-arm F5 at the alarm-ref reindex for refs a deploy adds while connected (defensive: today such a deploy
  respawns the driver because its RawTags are folded into its config).
- Nits: signals/edges from a retired or non-current child never (re)create a tracker; the injected clock replaces
  DateTime.UtcNow.
- Primary demote/re-promote: checked, not a stale-known window — drivers and their condition writes run ungated on
  both pair members.
2026-11-24 10:37:02 -05:00
Joseph Doherty 3c2cf96af2 test(grpc-data): A1 L4 — signal-latency LiveIntegration harness + measured evidence (OpcUaClient, FOCAS, MTConnect, AbCip; Galaxy/Heidenhain blocked) 2026-11-24 10:32:14 -05:00
Joseph Doherty 141e4412d2 test(grpc-data): A1 — real-driver signal rig (StartRig over IDriver), FOCAS end-to-end; driver test classes in the A1 manifest 2026-11-24 10:25:47 -05:00
Joseph Doherty 9167ea2323 feat(grpc-data): A1 — MTConnect signals after each full condition emission over a /current baseline 2026-11-24 10:22:18 -05:00
Joseph Doherty 4f1cefe8d8 docs(grpc-data): A1 drivers progress log 2026-11-24 10:19:41 -05:00
Joseph Doherty add4bc81e0 feat(grpc-data): A1 — Heidenhain signals per control after each Good alarm walk 2026-11-24 10:19:35 -05:00
Joseph Doherty 6ba5185f10 fix(grpc-data): A1 review S1 — a scripted condition is established only by a completed predicate
NoteInputsEstablishment raised 'established' before AreInputsReady, the evidence check and the predicate, so a
pushed-but-Bad input (driver down), a runner that was not up or a predicate timeout produced a known-inactive
record though no predicate had completed. The flip is now raised after the first predicate evaluation that
completes since the load or a revert; reverting an input to never-pushed still withdraws it.
2026-11-24 10:19:03 -05:00
Joseph Doherty 8f1be25673 feat(grpc-data): A1 — AbCip signals per node at the end of each ALMD/ALMA poll tick 2026-11-24 10:18:29 -05:00
Joseph Doherty e9d82a6a5a fix(grpc-data): A1 review B1 — a scripted projection never marks its condition known
WriteAlarmCondition set _conditionStateKnown for every projection. Scripted Active is not persisted, so the
post-restart re-assert of a restored unacked/shelved/disabled alarm (or the re-projection of an operator ack
before the inputs arrived) produced a known=true, Active=false record no predicate decided (T2 case i).
Only native transitions are established states now; scripted known-ness comes only from MarkConditionsKnown.
2026-11-24 10:17:34 -05:00
Joseph Doherty dbbc35e83d feat(grpc-data): A1 — FOCAS signals per device after each successful alarm read 2026-11-24 10:16:39 -05:00
Joseph Doherty 4e984b160e feat(grpc-data): A1 — OpcUaClient signals on RefreshEnd, sequential alarm publishing, Unsignalable without ConditionRefresh 2026-11-24 10:14:56 -05:00
Joseph Doherty b7f742efda feat(grpc-data): A1 — Galaxy raises InitialAlarmStateDelivered on every snapshot_complete sentinel 2026-11-24 10:10:30 -05:00
Joseph Doherty eb688a4ee0 Merge A1 keys/placements/ids into A1 core 2026-11-24 10:02:34 -05:00
Joseph Doherty 5a42948c37 docs(grpc-data): A1-core gates and open questions 2026-11-24 10:01:57 -05:00
Joseph Doherty 0eb533991b test(grpc-data): A1 — a strict publish-probe test ignores the new input-establishment mark 2026-11-24 09:53:36 -05:00
Joseph Doherty 1bc6a17ba9 docs(grpc-data): A1-core evidence — tests, mutations, driver-agent seams, scripted decisions 2026-11-24 09:49:31 -05:00
Joseph Doherty 81ebdf4fb0 test(grpc-data): A1 unit-phase manifest key 2026-11-24 09:39:27 -05:00
Joseph Doherty a248616761 feat(grpc-data): A1 scripted OnInputsEstablished — engine flip queued last in pending, host holds flips during a load until after the re-assert, MarkConditionsKnown on the alarm chain 2026-11-24 09:38:51 -05:00
Joseph Doherty 3ad6d7e8c7 docs(grpc-data): A1-core progress log — publish actor + driver signal done 2026-11-24 09:35:15 -05:00
Joseph Doherty 47bf3a1cad test(grpc-data): A1 native initial-state signal through the real driver actors — known only on signal, F2 delayed ordering, F5, backstop, G5; reusable NativeAlarmSignalTestBase + FakeSignallingAlarmDriver 2026-11-24 09:35:05 -05:00
Joseph Doherty ffdaa73d0c feat(grpc-data): A1 initial-alarm-state signal in DriverInstanceActor/DriverHostActor — ordered forward, MarkConditionsKnown routing, OpcUaClient backstop, F5 signal timeout + diagnostic 2026-11-24 09:30:32 -05:00
Joseph Doherty 45c38023a7 docs(grpc-data): A1 placements/keys/ids evidence, public API and deviations 2026-11-24 09:30:31 -05:00
Joseph Doherty d64578b1c5 feat(grpc-data): A1 MarkConditionsKnown in OpcUaPublishActor — deferred beside alarm states, replayed after them (F2), discarded on a source's dropped/skipped projection (G3) 2026-11-24 09:27:53 -05:00
Joseph Doherty f49e4e100b docs(grpc-data): A1-core progress log — NM + hub done 2026-11-24 09:24:43 -05:00
Joseph Doherty 923c2511a3 feat(grpc-data): A1 ConditionStateHub — bounded partitions, per-reader reset, snapshot_complete readiness, F5 diagnostic; wired to the node manager 2026-11-24 09:24:28 -05:00
Joseph Doherty 066372ce41 test(grpc-data): A1 — condition ids, condition_key (m-T6), secret validation, UNS-only no-RawPath property test; A1 manifest key 2026-11-24 09:23:06 -05:00
Joseph Doherty 6836efaeb9 feat(grpc-data): A1 origin condition state in the node manager — delta callback, state_known, activation marker, sliced snapshot, MarkConditionsKnown sink seam, IAlarmInitialStateSignal 2026-11-24 09:22:08 -05:00
Joseph Doherty cbc8d431f3 feat(grpc-data): A1 — realm-local condition placement enumeration and per-export condition listing 2026-11-24 09:18:08 -05:00
Joseph Doherty 6584c8535a feat(grpc-data): A1 — condition_key derivation (HKDF+HMAC) and DataConnections:ConditionKeySecret validation 2026-11-24 09:18:08 -05:00
Joseph Doherty 696f029349 feat(grpc-data): A1 — ImportedConditionIds: c1. condition identifier, child ids, mapped/conditions namespace 2026-11-24 09:18:07 -05:00
Joseph Doherty f7b0ff34d0 docs(grpc-data): A1-core progress log skeleton 2026-11-24 09:15:27 -05:00
Joseph Doherty cbb5b396bf Merge H4: remote-history diagnostics, metrics and docs (Gateway leg blocked, #923)
v2-ci / unit-tests (push) Waiting to run
2026-11-24 09:09:13 -05:00
Joseph Doherty 27d1501b69 docs(grpc-data): H4 evidence — review table, gates and live re-run after the review fixes 2026-11-24 09:08:52 -05:00
Joseph Doherty 7498f1ce82 test(grpc-data): H4 review 7 — diagnostics snapshot round-trips on the cluster serializer; old-shape payloads decode
Round-trips NodeDiagnosticsSnapshot (OriginHistory, HistoryVariants and the other H4 members) through
the serializer Akka picks for the fleet-diagnostics reply, and decodes payloads stripped of the H4
members. The origin flag is renamed NoPeerTrafficYet (default false): Akka's JSON serializer fills a
missing constructor argument with the CLR default, so a payload without it must never claim it.
2026-11-24 08:41:52 -05:00
Joseph Doherty 2fba036176 fix(grpc-data): H4 review 5+6 — AdminUI display: 'unavailable' without handshake evidence; every bit rendered
HistoryServed reads 'unavailable' when neither features nor variants were reported. Features()
and DroppedBits() render every set bit across all 32 (bit 31 included), named when known and hex
otherwise, so an unknown bit is never hidden beside a known one (#919).
2026-11-24 08:39:46 -05:00
Joseph Doherty 79cf50d50e fix(grpc-data): H4 review 4 — an origin chunk holding its page cursor is one open continuation, not two 2026-11-24 08:39:02 -05:00
Joseph Doherty b5509dfc48 docs(grpc-data): H4 review 3 — origin history reads are counted per item per wire call 2026-11-24 08:37:58 -05:00