Repository navigation
fix(relay): log every connection's close from Connection::run - #5602
Conversation
The interop harness keeps only the relay's `moq_relay::connection` and `moq_relay::relay` log targets. #5568 logged a WebSocket session's close from `moq_relay::websocket`, so the harness saw each WebSocket `conn{id=N}` open but never its close and failed the round as an idle-out. `Connection::run` now logs the close itself, in its own span and target, for every transport, and returns nothing; the QUIC, WebSocket, and moq-cli LAN accept loops stop logging it separately. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
kixelated
left a comment
There was a problem hiding this comment.
Automated review by review (OpenAI)
Reviewed commit: b7152b2.
No actionable bugs found. Keeping the close event in Connection::run fixes the target/filter mismatch at its source, rather than requiring the harness to know each transport's logging target. The stricter WebSocket regression covers the missed close, and the unchanged parser accepts the added span prefix. Panic isolation and success/error log levels remain equivalent; in-tree callers no longer duplicate the close.
The Result-to-unit API change is intentional and documented. io_uring remains outside this path as described, so this does not establish uniform logging for that backend.
Verification limits: static source, caller and harness review through GitHub. No tests, builds or interop runs executed by me.
|
Summary: the Interop idle-outs since #5568 came from a log filter, not from stuck sessions. The harness keeps only
(Written by Claude Opus 5.5) |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
Walkthrough
Priority: ➖ Normal Merge Risk: ⚪ Minimal · up to
|
Problem
Interop has failed on every PR since #5568 with
relay connection N (subscriber) idled out instead of closing (open). Every flagged connection istransport=websocket.The harness runs the relay with
RUST_LOG=<inherited>,moq_relay::connection=info,moq_relay::relay=info(#5215) and pairs eachconn{id=N}with aconnection closed id=Nline. #5568 numbered WebSocket sessions on the cluster counter and added their close log, but from targetmoq_relay::websocket, which that filter drops. The relay did close these sessions; the harness just never saw it. Before #5568, WebSocket ids came from a separate counter that collided with already-closed QUIC ids, which hid the same gap.The 13:07Z scheduled red run was unrelated: its failure was the wire-compat step's stale planned break, fixed separately.
Approach
Connection::runlogs its own close, inside itsconnspan and undermoq_relay::connection, for every transport. The QUIC and WebSocket accept loops and moq-cli's LAN path stop logging it themselves. One log site, one target, so a new transport can't drift again.The harness check is unchanged.
quest/m1/interop-close-log.mdis deleted: it pinned the harness filter to the close-log target and was only waiting on a green Interop run.Public API / wire impact
moq_relay::Connection::runnow returns()instead ofanyhow::Result<()>, since it reports the outcome itself. Every in-tree caller discarded or only logged the result. Breaking for embedders onmain.moq_relay::relaytomoq_relay::connectionand now carry theconn{...}span prefix. Theconnection closed id=N [err=...]text is unchanged.Validation
just test interop --all: rust round failed on WebSocket connections 6 and 7. With the fix, the full matrix passes ("interop: all checks passed").relay_websocket_logs_its_close_under_a_cluster_idnow captures logs through a filter that keeps onlymoq_relay::connection, matching the harness. It fails without the fix ("the WebSocket session's close was not logged") and passes with it.just checkpasses. One earlier run timed out inbursts_cross_a_transport_peer::impairedunder full parallel load. It passed 3/3 alone and in the rerun.Follow-ups
rs/moq-relay/src/uring.rs) doesn't go throughConnection::run, so it logsnegotiatedand its close undermoq_relay::uringwith noconnspan. Interop doesn't run it today.🤖 Generated with Claude Code