Bug #107651 Error packet for ER_CLIENT_INTERACTION_TIMEOUT not sent to client
Submitted: 24 Jun 2022 15:21 Modified: 1 Jul 2022 7:43
Reporter: Michal Kralik Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Router Severity:S2 (Serious)
Version:8.0.29 OS:Ubuntu (22.04)
Assigned to: CPU Architecture:x86
Tags: ER_CLIENT_INTERACTION_TIMEOUT, error

[24 Jun 2022 15:21] Michal Kralik
Description:
When MySQL closes a connection due to wait_timeout limit, the error packet related to the error is not forwarded by MySQL Router to the client connected to MySQL Router.

The connection to MySQL Router stays open and the client has no way of knowing the connection has been closed already without issuing a query over the connection. Subsequent query sent over the connection returns an error and a new connection needs to be opened.

How to repeat:
1. Configure MySQL Router to connect to MySQL 8.0.29
2. In MySQL, set wait_timeout to 5 seconds
3. Connect to MySQL Router
4. Wait 5 seconds
5. See packets received from MySQL Router

No packets are received after 5 seconds.

When connecting to MySQL 8.0.29 directly, after 5 seconds you receive an error packet with ER_CLIENT_INTERACTION_TIMEOUT error.

Suggested fix:
MySQL Router shall forward the error packet to the client.
[1 Jul 2022 7:43] MySQL Verification Team
Hello Michal Kralik,

Thank you for the report and feedback.

regards,
Umesh