You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "terrymanu (via GitHub)" <gi...@apache.org> on 2026/08/13 12:28:46 UTC

[PR] Refactor MySQL COM_QUERY original SQL byte handling [shardingsphere]

terrymanu opened a new pull request, #39444:
URL: https://github.com/apache/shardingsphere/pull/39444

   (no comment)


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Refactor MySQL COM_QUERY original SQL byte handling [shardingsphere]

Posted by "terrymanu (via GitHub)" <gi...@apache.org>.
terrymanu commented on PR #39444:
URL: https://github.com/apache/shardingsphere/pull/39444#issuecomment-5280501553

   ### Result
   
   **Review Result: Mergeable**
   
   No blocking correctness issues were found in the latest commit. This conclusion applies only to commit `4592c93de6bc`; the preceding four commits and the overall PR were not reviewed.
   
   ### Evidence
   
   - The reviewed range is [`65bcac25c805..4592c93de6bc`](https://github.com/apache/shardingsphere/commit/4592c93de6bc0639b214087b31a4c76075001207), containing four files according to both GitHub and the local diff.
   - [`MySQLComQueryPacket`](https://github.com/apache/shardingsphere/blob/4592c93de6bc0639b214087b31a4c76075001207/database/protocol/dialect/mysql/src/main/java/org/apache/shardingsphere/database/protocol/mysql/packet/command/query/text/query/MySQLComQueryPacket.java#L51-L76) retains the original payload bytes, while the string-based constructor still exposes no original bytes.
   - [`MySQLComQueryBackendHandlerFactory`](https://github.com/apache/shardingsphere/blob/4592c93de6bc0639b214087b31a4c76075001207/proxy/frontend/dialect/mysql/src/main/java/org/apache/shardingsphere/proxy/frontend/mysql/command/query/text/query/MySQLComQueryBackendHandlerFactory.java#L61-L110) now owns the binary-literal inspection. Standard SQL, valid `_binary` literals, malformed bytes, and multi-statement routing preserve the previous outcomes.
   - The MySQL documentation confirms that the COM_QUERY query is encoded as `string<EOF>` and that `_binary` is a valid character-set introducer: [COM_QUERY](https://dev.mysql.com/doc/dev/mysql-server/latest/page_protocol_com_query.html), [Character Set Introducers](https://dev.mysql.com/doc/refman/8.4/en/charset-introducer.html).
   - Focused verification passed:
     - `MySQLComQueryPacketTest`: 9 tests.
     - `MySQLComQueryBackendHandlerFactoryTest`: 8 tests.
     - `MySQLComQueryBinaryParameterExtractorTest`: 10 tests.
     - Total: 27 tests, 0 failures, 0 errors.
   
   ### Coverage
   
   - Reviewed head: `4592c93de6bc0639b214087b31a4c76075001207`
   - Behavior clusters: original SQL byte retention; binary-inspection and backend-handler routing.
   - Completed root-cause and behavior, blast-radius and contracts, tests and runtime, and final convergence passes.
   - All four files in the requested scope were accounted for, with no unresolved evidence gaps.
   - This is a code-scope result only. CI and the preceding commits were not reviewed.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Refactor MySQL COM_QUERY original SQL byte handling [shardingsphere]

Posted by "terrymanu (via GitHub)" <gi...@apache.org>.
terrymanu merged PR #39444:
URL: https://github.com/apache/shardingsphere/pull/39444


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org