MDEV-38008 - main.grant_kill fails sporadically#4414
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the grant_kill.test file to make the test more deterministic and focused by filtering the processlist queries to show only relevant connections instead of all system processes.
Key changes:
- Introduced
$default_idvariable to capture the default connection ID at the start of the test - Replaced
INFORMATION_SCHEMA.PROCESSLISTsubquery withconnection_id()function for getting current connection IDs - Added
WHEREclause filters toSELECTqueries on processlist to limit results to only the test-related connections - Removed
--source include/wait_until_count_sessions.inccalls that are no longer needed with the more focused approach
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| mysql-test/main/grant_kill.test | Refactored test to use connection IDs and filter processlist queries to only relevant connections |
| mysql-test/main/grant_kill.result | Updated expected results to match the new filtered processlist queries |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
39fc378 to
3056e9d
Compare
There was a problem hiding this comment.
Pull Request Overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
vuvova
left a comment
There was a problem hiding this comment.
okay, although it's kind of an overkill. Would be enough to have WHERE id = $id
@vuvova sure, strictly speaking this |
3056e9d to
cf8bb0f
Compare
Test output was affected by incompletely closed preceding connections.
Make test agnostic to concurrent connections by querying information_schema.processlist only for connections that it uses.
With bead24b all 3 processlist queries were affected. Before bead24b - only the first one.