Phase 6.1 Stream A (partial) - Polly resilience foundation: pipeline builder + CapabilityInvoker + per-tier defaults #78
Reference in New Issue
Block a user
Delete Branch "phase-6-1-stream-a-resilience"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
First PR on the phase-6.1-stream-a branch. Lands the resilience foundation + the CapabilityInvoker surface. Driver-dispatch wiring (Stream A.3 server-side wrap, Stream A.5 Modbus FlakeyTransport integration test, Stream A.6 attribute on tag-definition records) land in follow-up PRs on the same branch.
Summary
DriverResiliencePipelineBuilderinCore.Resilience. Polly v8 pipeline keyed on(DriverInstanceId, HostName, DriverCapability)per decision #144. One dead PLC behind a multi-device driver does not open the breaker for healthy siblings. Timeout ? Retry (capability-permitting, skipped for Write/AlarmAcknowledge by default, never on cancellation) ? CircuitBreaker (tier-permitting; Tier C disabled per decision #68). Lock-free pipeline cache.DriverResilienceOptions+CapabilityPolicyrecords. Per-tier � per-capability default table (Tier A/B/C � Read/Write/Discover/Subscribe/Probe/AlarmSubscribe/AlarmAcknowledge/HistoryRead).Resolve(capability)overlays per-instance overrides on defaults.CapabilityInvokerwrapper.ExecuteAsync(capability, host, callSite)resolves the pipeline from the shared builder.ExecuteWriteAsync(host, isIdempotent, callSite)is the explicit write-safety surface: non-idempotent writes route through a side pipeline with RetryCount=0 regardless of policy.WriteIdempotentAttributeinCore.Abstractions+DriverCapabilityenum +DriverTierenum. Attribute wiring ontoModbusTagDefinition/S7TagDefinition/OpcUaClient tag rows lands in the follow-up PR alongside the driver-dispatch routing.Proxy/Supervisor/CircuitBreaker.cs+Backoff.cs+HeartbeatMonitor.cspreserved (no-op verification; they guard IPC respawn per decision #68, orthogonal to the per-call Polly layer).Test plan
dotnet test: 936 passing, 1 pre-existing Client.CLI Subscribe flake unchanged.CapabilityInvokerintoServerdispatch + apply[WriteIdempotent]to driver tag-definition records + FlakeyTransport integration tests.🤖 Generated with Claude Code