Runtime.Tests: Two_sdk_cadences_renew_before_expiry... residual ~1% hang under load (cohort rebind never completes; barrier hook vs cross-cadence handshake) #968
Reference in New Issue
Block a user
Delete Branch "%!s()"
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?
Residual flake left after #965's pacing fixes:
Two_sdk_cadences_renew_before_expiry_without_reviving_old_notification_evidencestill fails ~1% of runs (2-5 per 240) under extreme load (16 parallel lanes + 16 busy loops on 14 cores), on BOTH the old and the new pacing (original baseline: 6/240).Mode: after the metadata renewal both cadences' cohorts rebind (RemoveSubscriptionItems -> AddSubscriptionItems), but one cohort never completes: diagnostics show e.g.
slow(add=0,rem=1)/fast(add=1,rem=2),demands=[] items=[](everything torn down), or a settle/NextPublished wait that never ends (a renewal tick queued but never handled, i.e. the cohort loop is blocked or dead). The test'sBeforeSuccessorAdoptionForTestshook is aBarrier.SignalAndWaitthat blocks a pool thread insidePublish. Suspects: (a) the barrier waits on a cohort whose Publish never reachessuccessor != null(e.g.TryPrepareSuccessortakes theReferenceEquals(_proof, captured)/_previousProofshortcut), so the waiter times out and its attempt dies; (b) a real product race in the cross-cadence successor handshake. Not determined which.Repro: build Runtime.Tests, copy bin/Debug/net10.0 aside, run the two renewal tests in 16 parallel loops next to CPU burners. Not investigated further.
Related: #965.
Real production race, fixed in
464f8d485(merged708a4889c). OtOpcUaNodeManager.TryResolve/TryResolveForRenewal read the committed-definition map twice and reported a node missing if a renewal replaced the definition in between. Demand checks then killed the stream attempt (Source unavailable / freshness break), which caused the barrier timeouts. They now re-check the replacement (bounded at 16). Lookup race test: about 19% missing before, 0 after. Stress: 9/1814 before, 0/960 after. Runtime DataConnections 1028/1028, OpcUaServer DataConnections 63/63. Redundant double renewal filed as a p3 follow-up.