Skip to content

fix(server): CLIENT TRACKING unreachable on monoio runtime (H-3 reorder regression)#277

Merged
pilotspacex-byte merged 1 commit into
mainfrom
fix/client-tracking-monoio-intercept
Jul 11, 2026
Merged

fix(server): CLIENT TRACKING unreachable on monoio runtime (H-3 reorder regression)#277
pilotspacex-byte merged 1 commit into
mainfrom
fix/client-tracking-monoio-intercept

Conversation

@pilotspacex-byte

@pilotspacex-byte pilotspacex-byte commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

CLIENT TRACKING ON|OFF has been answering ERR unknown subcommand 'TRACKING' on the monoio runtime (the production default) since the H-3 ACL reorder in #258 — at every shard count. RESP3 client-side caching / invalidation push has been entirely unavailable on prod builds for ~1 day.

Root cause

In handler_monoio's frame loop, try_handle_client_admin runs before try_handle_client_tracking. The admin handler's unknown-subcommand catch-all consumed TRACKING and emitted the error before the dedicated tracking handler could see it. Its doc comment claimed to skip TRACKING, but the code did not.

Why CI missed it

The test matrix exercises the tokio handler (handler_sharded), whose CLIENT intercept ordering differs — so all 5 client_tracking_invalidation black-box tests kept passing there while failing deterministically against a monoio binary. (Filed a follow-up note: monoio-only intercept-order bugs are CI-blind; test monoio binaries locally when reordering.)

Fix

try_handle_client_admin now returns false (falls through) for TRACKING, letting try_handle_client_tracking own it. Both handlers sit after the ACL gate, so the H-3 deniability guarantee is unchanged.

Verification

  • All 5 client_tracking_invalidation black-box tests re-green against the monoio binary. Control-tested: 5/5 FAILED at the merge base (3c516943) with the same binary, confirming this is the fix and the tests are valid.
  • cargo fmt --check, clippy -D warnings clean on default + runtime-tokio,jemalloc feature sets.

Regression from #258 · tests from #234

Summary by CodeRabbit

  • Bug Fixes
    • Fixed an issue where CLIENT TRACKING commands failed on the monoio runtime.
    • Client tracking requests are now correctly routed and handled instead of being reported as unknown subcommands.
    • Restored related client tracking invalidation behavior.

…consumed it

Since the H-3 ACL reorder (#258), CLIENT TRACKING ON|OFF answered
"ERR unknown subcommand 'TRACKING'" on the monoio runtime (the
production default) at every shard count. try_handle_client_admin runs
before try_handle_client_tracking in the frame loop, and its
unknown-subcommand fallback consumed TRACKING before the dedicated
handler could see it — RESP3 invalidation push was entirely dead.

Invisible to CI: the test matrix runs the tokio handler
(handler_sharded), whose CLIENT intercept ordering differs, so all 5
client_tracking_invalidation black-box tests kept passing there while
failing deterministically against a monoio binary.

Fix: try_handle_client_admin falls through (returns false) for
TRACKING, letting try_handle_client_tracking own it. Both handlers sit
after the ACL gate, so the H-3 deniability guarantee is unchanged.

Verification: all 5 client_tracking_invalidation tests re-green against
the monoio binary (were 5/5 FAILED at the merge base, control-tested);
fmt + clippy clean on default and runtime-tokio,jemalloc feature sets.

Refs: regression introduced by #258; tests from #234
author: Tin Dang
@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: e471a284-84ae-4017-9391-2b5fca6e65c3

📥 Commits

Reviewing files that changed from the base of the PR and between 3c51694 and b014340.

📒 Files selected for processing (2)
  • CHANGELOG.md
  • src/server/conn/handler_monoio/dispatch.rs

📝 Walkthrough

Walkthrough

The monoio CLIENT dispatcher now lets CLIENT TRACKING fall through to its dedicated post-ACL handler instead of returning an unknown-subcommand error. The regression and associated test verification are documented in the changelog.

Changes

CLIENT TRACKING dispatch

Layer / File(s) Summary
Allow tracking fall-through
src/server/conn/handler_monoio/dispatch.rs, CHANGELOG.md
try_handle_client_admin returns false for CLIENT TRACKING, allowing the dedicated handler to process it; the monoio regression and test verification are documented under Unreleased.

Estimated code review effort: 2 (Simple) | ~5 minutes

Possibly related PRs

  • pilotspace/moon#258: Reorders monoio CLIENT TRACKING handling behind the ACL gate in the same dispatcher.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the monoio CLIENT TRACKING regression and the server fix.
Description check ✅ Passed The description gives a strong summary, root cause, fix, and verification, though it doesn't match the template headings exactly.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/client-tracking-monoio-intercept

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@pilotspacex-byte
pilotspacex-byte merged commit 257a3dc into main Jul 11, 2026
10 checks passed
@TinDang97
TinDang97 deleted the fix/client-tracking-monoio-intercept branch July 11, 2026 00:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants