MilanTyagi2004 commented on PR #37472:
URL: https://github.com/apache/shardingsphere/pull/37472#issuecomment-3689758553
> We’ve overcomplicated this. The real goal is just to make Kill/Cancel hit
the running process. The chatter exploded because the scope ballooned: we mixed
in 64-bit global IDs, cross-node forwarding, persistence, and even
Firebird/OpenGauss while the client protocol still exposes 32-bit IDs, and we
never nailed a clear mapping. On top of that, we touched 70+ files before
agreeing on the design, so formatting/compat issues drowned out the core fix.
>
> Let’s simplify and get back on target:
>
> * Pick one rule and make “handshake ID == lookup ID” work end to end.
Either stay with 32-bit and align MySQL/PostgreSQL handshake, ProcessRegistry,
and Kill/Cancel, or if we keep 64-bit, define an exact mapping so the 32-bit
client ID can resolve to the stored 64-bit.
> * Fix the main MySQL/PostgreSQL path only: handshake → process bind →
registry lookup → Kill/Cancel. Don’t fan out to other protocols yet.
> * Pause unrelated formatting/refactors and shrink the diff.
> * Add a few focused tests: local/(if needed) cross-node, secret key
checks, and the ID mapping.
>
> First make the core path reliable; discuss global IDs/bitset allocation
separately afterward.
Post this as your reply. Keep it short and aligned with his direction:
Thanks for the clarification. I agree the scope grew too large and diluted
the core fix.
I’ll reset this PR to focus only on the essential path:
handshake → process bind → registry lookup → Kill/Cancel, limited to MySQL
and PostgreSQL.
Plan:
1. Pick a single rule so handshake ID == lookup ID end-to-end. I’ll stay
with 32-bit IDs for now and align handshake,
ProcessRegistry, and Kill/Cancel accordingly.
2. Remove all unrelated changes (Firebird/OpenGauss, formatting, refactors)
and shrink the diff.
- Add focused tests covering:
- handshake → bind → cancel/KILL (local)
3. PostgreSQL secretKey validation
4. Defer 64-bit global IDs, cross-node forwarding, persistence, and
allocation/bitset discussions to a separate issue.
I’ll update the PR with a minimal, clean diff following this approach.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]