Retain ServiceLevel requests across binding and publisher failures #720

Merged
dohertj2 merged 3 commits from fix/servicelevel-binding-replay into master 2026-10-13 15:58:22 -04:00
Owner

ServiceLevel requests made before the SDK publisher was bound were lost, leaving the SDK default 255 visible to clients. Failed SDK writes could also advance actor deduplication and prevent recovery. Retain and serialize the latest request, replay it on binding (including zero), propagate SDK failures, and deduplicate only after successful publication; invalidate deduplication after any failure.

If binding fails after endpoint startup, detach bindings and observe SDK stop before disposal. Preserve ownership when cleanup faults so final shutdown can retry. Guard disposal against the already-halted SDK CurrentInstance getter while allowing the admin host to continue booting.

Validation: 2,381 passed and 4 existing retired-v3 skips across affected Commons, SDK, Runtime, Host and targeted integration suites. Independent root loopback rerun passed both real client reads of ns=0;i=2267 (100 and 0). Lock-removal and dedup-invalidation mutations failed as intended and were restored. Reviewed independently; diff check clean. No live device/historian calls or deployment.

The real Host fault test injects publisher-construction failure after confirming a listener, then verifies closure and continued admin boot. Actual Host replay/SDK-stop failure coverage is composition evidence from separate adapter/SDK and cleanup-callback tests; persistent SDK failure is not claimed to guarantee endpoint closure. Health arithmetic, election and Warm mode remain separate work under #717.

Resolves #719 after hosted full CI passes.

Integration update: latest head 8828e999c4 includes merged main PR #714. Both integration merge commits preserve the combined tree a7ce6c7688e5aa5e28c47519fd526c809306f93e; 11 diagnostic guard fixtures were rerun successfully. Required hosted run #983 passed on the final head: all steps successful, 62 TRX files, 14,648 executed, 573 individual skips, minimum 12,000, artifacts finalized. Merged as 1bf8c614; merged tree a7ce6c7688 exactly equals the tested tree. Earlier run #980 tests the previous c8e3e279 tree and will not substitute for the final head.

ServiceLevel requests made before the SDK publisher was bound were lost, leaving the SDK default 255 visible to clients. Failed SDK writes could also advance actor deduplication and prevent recovery. Retain and serialize the latest request, replay it on binding (including zero), propagate SDK failures, and deduplicate only after successful publication; invalidate deduplication after any failure. If binding fails after endpoint startup, detach bindings and observe SDK stop before disposal. Preserve ownership when cleanup faults so final shutdown can retry. Guard disposal against the already-halted SDK CurrentInstance getter while allowing the admin host to continue booting. Validation: 2,381 passed and 4 existing retired-v3 skips across affected Commons, SDK, Runtime, Host and targeted integration suites. Independent root loopback rerun passed both real client reads of ns=0;i=2267 (100 and 0). Lock-removal and dedup-invalidation mutations failed as intended and were restored. Reviewed independently; diff check clean. No live device/historian calls or deployment. The real Host fault test injects publisher-construction failure after confirming a listener, then verifies closure and continued admin boot. Actual Host replay/SDK-stop failure coverage is composition evidence from separate adapter/SDK and cleanup-callback tests; persistent SDK failure is not claimed to guarantee endpoint closure. Health arithmetic, election and Warm mode remain separate work under #717. Resolves #719 after hosted full CI passes. Integration update: latest head 8828e999c41057ae7b9d84573228ab8caf71fe06 includes merged main PR #714. Both integration merge commits preserve the combined tree a7ce6c7688e5aa5e28c47519fd526c809306f93e; 11 diagnostic guard fixtures were rerun successfully. Required hosted run #983 passed on the final head: all steps successful, 62 TRX files, 14,648 executed, 573 individual skips, minimum 12,000, artifacts finalized. Merged as 1bf8c614; merged tree a7ce6c7688e5aa5e28c47519fd526c809306f93e exactly equals the tested tree. Earlier run #980 tests the previous c8e3e279 tree and will not substitute for the final head.
dohertj2 added 1 commit 2026-10-13 13:26:56 -04:00
dohertj2 added 4 commits 2026-10-13 13:55:00 -04:00
dohertj2 added 1 commit 2026-10-13 13:56:31 -04:00
dohertj2 merged commit 1bf8c614a9 into master 2026-10-13 15:58:22 -04:00
Sign in to join this conversation.