docs(grpc-data): A2a evidence — tests, mutation checks, gates, live smoke a2a-cond-2 PASS
This commit is contained in:
@@ -6,11 +6,12 @@ the `AddDataConnectionConditions` migration. Condition METHODS are stage A2b (a
|
||||
|
||||
## Progress log (resume from here)
|
||||
|
||||
- **Done:** `Understood` += AlarmSubscribe (`a74a1aee`); config slice — migration/validator/AdminUI/F-P-U tests (`ac945563`,
|
||||
`ee1556ac`, `6272c7cf`, helper agent); contract + codecs (`73142e52`); origin streaming + host negotiation + consumer decode
|
||||
(`5b03c8a2`); Runtime R tests `GrpcDataConditionStreamTests` 12/12 ×5 (`14ab6be3`).
|
||||
- **In progress:** Commons codec/reservation tests; Host wire tests (header-less never arm 9) + v1 gates.
|
||||
- **Next:** manifest key A2; gates; live smoke; docs.
|
||||
- **Done (A2a complete on this branch):** `Understood` += AlarmSubscribe (`a74a1aee`); config slice — migration/validator/
|
||||
AdminUI/F-P-U tests (`ac945563`, `ee1556ac`, `6272c7cf`, helper agent); contract + codecs (`73142e52`); origin streaming +
|
||||
host negotiation + consumer decode (`5b03c8a2`); R tests (`14ab6be3`); codec pins (`6bb8fa69`); v1 gates extended
|
||||
(fake + real origin); manifest key `A2`; rig `--conditions` profile + probe scenario + `conditions_smoke.py`; byte-bounded
|
||||
chunks (`1977d8ce`); live smoke PASS (run `a2a-cond-2`).
|
||||
- **Next (A2b):** condition methods — see "Seams for A2b".
|
||||
|
||||
## What changed
|
||||
|
||||
@@ -58,6 +59,69 @@ entity JSON (pre-A2 artifact parses with defaults) and are not in `DataConnectio
|
||||
AlarmAcknowledge, so it stays false until A2b), and `DataConnectionValidator.ConditionCapacityWarnings` (Σ mapping
|
||||
MaxConditions × 49 > 122,500 per consumer node; shown on the AdminUI mappings panel, not yet logged on deploy).
|
||||
|
||||
## Tests (Phase A2 traits; manifest key `A2`)
|
||||
|
||||
| Key | Project | Classes |
|
||||
|---|---|---|
|
||||
| R | Runtime | `GrpcDataConditionStreamTests` (12): snapshot begin/total/records/complete + delta; total over the limit first and only (no `SnapshotConditions` call); slice cut with deltas between holds (no gap, no duplicate); hub reader reset ⇒ fresh snapshot; overflow while the snapshot is undelivered ⇒ stream `Reset`; priority (control at head, then condition, then value; a control behind a value keeps v1 order); revocation mid-snapshot ⇒ no further condition record, stream ends, item released; deploy add/remove ⇒ delta records (`removed`); UNS listing carries no RawPath/driver id; non-Primary ⇒ `Unavailable`, no grant ⇒ `Denied`; incomplete apply ⇒ snapshot without `snapshot_complete`, retaken complete; capabilities only with a key secret |
|
||||
| — | Commons | `GrpcDataConditionCodecTests` (6): 17/4/9 pinned with their real types (replaces the X0 tripwire), full-field round trip, begin `total` presence, malformed frames refused, bit 64 without field 17 is no grant, a plain item stays v1 bytes |
|
||||
| v1 gate | Host | `GrpcDataV1CompatibilityTests` / `GrpcDataV1RealOriginCompatibilityTests`: both origins now serve conditions (fake: field 17 + bit 64 + an arm-9 frame for a scoped item; real: AlarmSubscribe exports + a condition source over the HighTemp alarm). Header-less ⇒ golden bytes on every RPC, including a Subscribe whose items carry `condition_scope` (no arm 9); with the header ⇒ field 17/bit 64 and (fake) arm 9. `git diff master -- *Goldens.cs` is empty |
|
||||
| F | Configuration | `GrpcDataConditionConfigurationTests` (22) + updated `GrpcDataReservedOperationAuthoringTests` |
|
||||
| P | Runtime | `GrpcDataConditionArtifactReadTests` (10) |
|
||||
| U | AdminUI | `GrpcDataConditionEditorTests` (5) |
|
||||
|
||||
Also updated for the new understood bit/probe header: `GrpcDataOperationToleranceTests`, `GrpcDataFeatureHeaderTests`,
|
||||
`GrpcDataFeatureHeaderClientTests`, `GrpcDataHistoryClientTests`, `GrpcDataUnknownOperationToleranceTests`,
|
||||
`GrpcDataArtifactReadTests`, `GrpcDataHistoryEditorTests` (each now uses a still-reserved bit, 128+, as "unknown").
|
||||
|
||||
**Mutation checks (red, then restored green):** skipping the slice-watermark check ⇒ the slice-cut, deploy tests red;
|
||||
`snapshot_complete := true` ⇒ the incomplete-apply test red; removing `StripConditionScopes` in the host ⇒ both header-less
|
||||
arm-9 gates red (fake and real origin); helper agent: AllowGalaxyServiceAck rule, mapping MaxConditions bound,
|
||||
AlarmSubscribe authorability.
|
||||
|
||||
## Gates
|
||||
|
||||
| Gate | Result |
|
||||
|---|---|
|
||||
| `dotnet build ZB.MOM.WW.OtOpcUa.slnx` | 0 warnings, 0 errors |
|
||||
| `run-unit-phase.py` A2, A1, H2, X0 | all passed (A1 failed once in an earlier run on `NativeAlarmInitialStateSignalTests.A_native_transition_leaves_the_F5_pending_set…`, an A1 timing test untouched here; 6/6 green alone, then green in the final phase run) |
|
||||
| Host.Tests `.DataConnections.` | 201 passed (both v1 gates included) |
|
||||
| Runtime.Tests (`Category!=E2E&Category!=LiveIntegration`) | 1980 passed, 3 skipped (first run: the revocation test raced the worker teardown — fixed by awaiting `Completion`; `VirtualTagActorTimerTests.Ticks_during_a_slow_run…` failed once under load, 3/3 green alone, unrelated) |
|
||||
| OpcUaServer.Tests | 1439 passed, 1 skipped |
|
||||
| Commons / Core.Abstractions / Configuration / AdminUI | 510 / 860 / 343 / 2703 passed |
|
||||
| `test_unit_phase_runner.py` + `tests/test_compose_fixture.py` | 35 passed |
|
||||
|
||||
## Live smoke (rig) — run `a2a-cond-2`, PASS
|
||||
|
||||
Standalone rig (OrbStack), build `d3a4e70f6` (clean tree, recorded `source_tree_hash` `b6c0019b8b01b7f9…`; normal build-hash
|
||||
checks, no pinning).
|
||||
|
||||
```bash
|
||||
python3 scripts/validation/grpc-data/rig.py up --run-id a2a-cond-2 --conditions --timeout 1200
|
||||
python3 scripts/validation/grpc-data/rig.py seed --run-id a2a-cond-2
|
||||
# ~80 s for CONTROL's ClusterNode contact refresh
|
||||
python3 scripts/validation/grpc-data/rig.py deploy --run-id a2a-cond-2 --timeout 300
|
||||
python3 scripts/validation/grpc-data/conditions_smoke.py --run-id a2a-cond-2
|
||||
python3 scripts/validation/grpc-data/rig.py down --run-id a2a-cond-2
|
||||
```
|
||||
|
||||
| Item | Observed | Result |
|
||||
|---|---|---|
|
||||
| Capabilities without / with `conditions` | source-1 (Primary): ops 31 / 95, no field 17 / `{rootScopeItems, maxConditions 1000}`; source-2 (Secondary): 23 / 87, same field | PASS |
|
||||
| Primary: condition item on the UNS equipment root | ack Good; begin `total` 1; one record `ScalarHigh` — active, `state_known`, severity 500, info `{nsu=http://opcfoundation.org/UA/;i=2915, ScalarHigh, SCRIPTED, uns|source-scalar-high}`; `snapshot_complete`; frames Ack, ConditionStates ×3 | PASS |
|
||||
| Delta | probe sets scalar 0 ⇒ one delta record, same key, version 3 → 4, inactive, known, no info | PASS |
|
||||
| No RawPath on the UNS stream | no `modbus/plc` in any record | PASS |
|
||||
| Secondary | condition item ack `Unavailable` (Primary-only) | PASS |
|
||||
| Teardown | `rig.py down`; no run-labelled containers, volumes or networks left | — |
|
||||
|
||||
Earlier attempts (kept as history): `a2a-cond-1` — first the smoke script lacked `ScenarioRunner.publish()`/deadline; then the
|
||||
probe addressed the equipment root by path instead of its catalog identifier (`NotFound`) and with the wrong subject
|
||||
(`Denied`); fixed in `d3a4e70f6` (harness only), then a fresh run. The CONSUMER's AdminUI page now shows "Negotiated features
|
||||
Conditions" (the consumer probe asks for `conditions`; nothing else changes until a condition item is opened).
|
||||
|
||||
**Not verified live:** the AdminUI condition editor fields (the page returns 200 with the prerendered diagnostics; the
|
||||
editor modals were not driven — no bUnit, needs a browser drive in A4 or the next rig session).
|
||||
|
||||
## Decisions
|
||||
|
||||
1. **No `Control NotReady` kind.** §5.1 says "until then the stream sends a Control NotReady"; `DataStreamControlKind` has
|
||||
|
||||
Reference in New Issue
Block a user