Commit graph

3 commits

Author SHA1 Message Date
Teknium
b1201213b7 fix(gateway): honest durable ack semantics for undeliverable async completions
Adapter acceptance is not proof of delivery: the inner #55578 resolver can
still fail closed inside the message pipeline after the adapter accepted the
synthetic event, which falsely acknowledged the durable row as delivered and
silently discarded the delegation result.

Pre-flight the delivery target in _deliver_completion_notification before
adapter acceptance (adapted from #65838 by @henrynguyeninfo1):
- live parent or verified live compression tip -> deliver (inner resolver
  still owns the actual route retarget)
- explicit-reset / unknown parent -> terminal 'dropped' disposition via new
  drop_completion_delivery() (not falsely 'delivered', not eternally
  'pending')
- transient uncertainty (DB error, mid-flight rotation without a visible
  continuation) -> release the claim for retry

release_completion_delivery() now converges to a terminal 'dropped' state
once _MAX_DELIVERY_ATTEMPTS is exhausted, so an undeliverable completion
cannot replay on every gateway restart forever.
2026-07-22 06:56:08 -07:00
teknium1
d0e9a42cec fix(delegation): harden durable completion delivery 2026-07-13 07:28:21 -07:00
John Lussier
94a7705bdd fix(gateway): deduplicate completion delivery 2026-07-13 07:28:21 -07:00