carlos / platform Public

Region HA: close-lost leaves a departed member's edges record admitted Issue closed

Region HA: after carlos system group close-lost, the departed member's control/edges/<box>.json stays published as admitted, serving its pool and draining. Nothing retired it in 40 minutes, and every later drain in the group waits on it and fails. Found on dev IE during the PPv2 cutover window, 2026-11-17. All times UTC.

Timeline:

  • 08:26:30 group replace --member i-06fa63a3a4df904f2 (box g-03152630d13dc3375e31, 172.31.27.196). Drain, edge-stop and terminate went cleanly, and its edges record was last written 08:28:52 with draining: true, ha_drained: true, ha_drain.txn ae7c53ab....
  • The replacement (LT 31) failed at boot for an unrelated reason: dev stable had moved to v0.38.0 with no group re-pin, and install-channel refuses a channel release that differs from the pin. At 08:43:59 the verb refused with "The replacement or the departure did not finish in time", leaving the transaction open.
  • 08:53:59 re-pin to LT 32 applied. 09:02 a new member, i-067fc31d, was InService.
  • 09:03:05 resume refused: "The member set or capacity changed outside this transaction". 09:03:37 close-lost closed it: "Transaction closed with outcome failed-member-lost. This does not record recovery."
  • 09:04-09:09 group replace --member i-0c10fe12329b26a9b failed in drain: "the draining state was not acknowledged by [g-03152630d13dc3375e31 (ha-drain: ask g-03152630d13dc3375e31 (172.31.27.196): context deadline exceeded)]". The member was returned to service, and cancel-drain lifted the fence.
  • 09:12 the record was still there: admitted: true, served_pools: ["hapair"], draining: true, generation 08:28:52Z. i-06fa63a3 was terminated at 08:31:21, and no other edges file or live lock named the box. The one lock naming it, g6x.bab.dev.oncarlos.com, is a released lock from 11-14.
  • 09:12:55 the record was deleted by hand on the agent manager's go (delete marker L7ECt5ln; prior version aA.eOYqQ kept). The replace was then retried.

What's wrong:

  1. close-lost closes the journal but never finishes the departure. The dead member's edges record stays admitted, serving its pool and draining.
  2. No housekeeper retired a member whose instance had been terminated for 40 minutes. The region HA rule is that a dead member retires within 5 minutes, even under churn.
  3. Every later drain asks that record to acknowledge and times out, so no member of the group can be drained, replaced or rolled until someone deletes the record by hand.

Wanted: close-lost, or the housekeeper, retires the departed member's edges record once the instance is confirmed terminated. A test should show a drain after close-lost succeeding without any manual step.

Evidence: verb output in ~/.cache/ppv2-cutover/gprobe/replace-*.txt and the journal ~/.carlos-group-state/carlos/group/56ce35c531f9b1168e7d007ed5cbf79e/ae7c53ab0613d16b0640bbc2df414764.v2.jsonl (DOCS-T1).

Fixed by 4a81517 (branch ha-1192-close-lost-edges). Cause: the departure of g-03152630 was held forever by trashed app bab/g6x's host, whose released lock named the member; close-lost was a bystander. Merged, not released.

Fix merged as 887caf2b16a29dfea99daa36bf58d6614feb1c66 (squash of ha-departure-evidence). Not released yet; it rides the next release on Paul's GO.

Cause of the hourly code=evidence page. On dev IE i-08a5a9b1 (journal read only, read-only), the identity of g-03152630 / i-06fa63a3a4df904f2 was bound with an empty observation. Its control/edges record had been deleted by hand on 11-17, and only an observation of that record can fill one. enqueue refused the empty observation every pass, and the loop paged code=evidence hourly. The termination proof does exist. The 11:52Z lock.json delete was unrelated: the departure was still deferred at 14:17Z.

Fix. This case now pages once with code=evidencenoobservation and stays pending. The member is never declared gone on this path. The hint is marked paged only after a real delivery, and the mark survives restarts, transient failures and older registry servers. Only removing the hint clears it. A guard test covers every journal op sequence.

Review. Astra rounds 1-4, the fourth approved by Paul. Census approved, recorded on #280. CI green on de0094f8.

After the release, dev IE pages once more, then goes quiet. The stale hint and identity row stay as harmless pending state. A follow-up branch for an operator verb, carlos ops ha-departures forget <g-ref> (dry-run by default, refused unless a termination proof exists and no lock or edges record names the member), will clear them. It gets its own UX pass and Paul's copy review.