[MXS-4004] Race condition in KILL command execution Created: 2022-02-16 Updated: 2022-02-24 Resolved: 2022-02-23 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | Core |
| Affects Version/s: | 2.5.19, 6.2.2 |
| Fix Version/s: | 2.5.20, 6.2.3 |
| Type: | Bug | Priority: | Major |
| Reporter: | markus makela | Assignee: | markus makela |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Description |
|
To reproduce, run the following SQL with the mariadb client with --delimiter=// option:
Once the query has started, interrupt it with Ctrl+C. With a direct connection to the database the connection is killed immediately but with MaxScale the KILL command it generates doesn't end up being processed correctly. There's possibly a race condition of sorts where the execution of the sub-KILL commands that are derived from the original one end up being discarded due to the fact that the session is stopping. If this is true then the solution is to wait until all the sent commands have been written to the network before the OK packet is sent for the original KILL command. |