feat(runway): dlq reconciler for merge topics - #459
Merged
Conversation
This was referenced Jul 29, 2026
behinddwalls
marked this pull request as ready for review
July 30, 2026 14:47
behinddwalls
force-pushed
the
preetam/runway-terminal-errors
branch
from
July 30, 2026 16:12
24ac344 to
8878096
Compare
behinddwalls
force-pushed
the
preetam/runway-dlq-reconciler
branch
from
July 30, 2026 16:12
6c0f8d9 to
42a0cd1
Compare
behinddwalls
marked this pull request as draft
July 30, 2026 16:14
behinddwalls
force-pushed
the
preetam/runway-terminal-errors
branch
from
July 30, 2026 16:15
8878096 to
930df02
Compare
behinddwalls
force-pushed
the
preetam/runway-dlq-reconciler
branch
from
July 30, 2026 16:16
42a0cd1 to
d8ee8ae
Compare
behinddwalls
marked this pull request as ready for review
July 30, 2026 17:06
behinddwalls
force-pushed
the
preetam/runway-terminal-errors
branch
from
July 30, 2026 17:13
930df02 to
8ee23c0
Compare
behinddwalls
force-pushed
the
preetam/runway-dlq-reconciler
branch
from
July 30, 2026 17:13
d8ee8ae to
b358333
Compare
kevinlnew
approved these changes
Jul 30, 2026
behinddwalls
force-pushed
the
preetam/runway-terminal-errors
branch
from
July 30, 2026 17:55
8ee23c0 to
133a045
Compare
behinddwalls
force-pushed
the
preetam/runway-dlq-reconciler
branch
from
July 30, 2026 17:55
b358333 to
d976bb9
Compare
## Summary ### Why? SubmitQueue records in-flight merge work before publishing and then waits for exactly one `MergeResult` echoing its correlation id. Runway is stateless and the sole responder on that id, so every request must resolve to a result — or the client waits forever. The primary controllers resolve what they can name: conflicts and invalid requests become a `FAILED` result, infrastructure faults are nacked for retry. But a fault that never recovers exhausts the retry budget and dead-letters. Nothing consumed those dead-letter topics, so the request produced no signal at all and the client's correlation id hung indefinitely. ### What? Adds `runway/controller/dlq`, a reconciler that subscribes to an inbound topic's `_dlq` queue and, for each dead-lettered `MergeRequest`, republishes a `FAILED` `MergeResult` echoing the correlation id to the corresponding signal topic. `dlq.TopicKey` derives the DLQ topic key from the primary one so the two stay in lockstep. Unlike the SubmitQueue and Stovepipe DLQ reconcilers this one writes no entity state — Runway has none, and the signal *is* the resolution. A payload that cannot be decoded carries no correlation id and is dropped rather than retried forever. Wires two instances in the server (one per inbound topic) on a dedicated consumer running under `errs.AlwaysRetryableProcessor`, so a transient publish failure retries indefinitely rather than dead-lettering the dead-letter. The DLQ consumer is started alongside the primary one and stopped with the same 30s drain on shutdown; both stop errors are joined into the exit status. ## Test Plan ✅ `bazel test //runway/...` — 5/5 pass, including new `//runway/controller/dlq` coverage for republish-on-dead-letter, the drop-undecodable-payload path, and publish-failure propagation ✅ `bazel build //service/runway/...` — wiring compiles ✅ `make gazelle`, `make fmt`
behinddwalls
force-pushed
the
preetam/runway-dlq-reconciler
branch
from
July 30, 2026 18:05
d976bb9 to
c766cf8
Compare
This was referenced Jul 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Why?
SubmitQueue records in-flight merge work before publishing and then waits for exactly one
MergeResultechoing its correlation id. Runway is stateless and the sole responder on that id, so every request must resolve to a result — or the client waits forever.The primary controllers resolve what they can name: conflicts and invalid requests become a
FAILEDresult, infrastructure faults are nacked for retry. But a fault that never recovers exhausts the retry budget and dead-letters. Nothing consumed those dead-letter topics, so the request produced no signal at all and the client's correlation id hung indefinitely.What?
Adds
runway/controller/dlq, a reconciler that subscribes to an inbound topic's_dlqqueue and, for each dead-letteredMergeRequest, republishes aFAILEDMergeResultechoing the correlation id to the corresponding signal topic.dlq.TopicKeyderives the DLQ topic key from the primary one so the two stay in lockstep.Unlike the SubmitQueue and Stovepipe DLQ reconcilers this one writes no entity state — Runway has none, and the signal is the resolution. A payload that cannot be decoded carries no correlation id and is dropped rather than retried forever.
Wires two instances in the server (one per inbound topic) on a dedicated consumer running under
errs.AlwaysRetryableProcessor, so a transient publish failure retries indefinitely rather than dead-lettering the dead-letter. The DLQ consumer is started alongside the primary one and stopped with the same 30s drain on shutdown; both stop errors are joined into the exit status.Test Plan
✅
bazel test //runway/...— 5/5 pass, including new//runway/controller/dlqcoverage for republish-on-dead-letter, the drop-undecodable-payload path, and publish-failure propagation✅
bazel build //service/runway/...— wiring compiles✅
make gazelle,make fmtStack