Add the ability to send app-layer keepalive pings#1553
Conversation
b5e6ea6 to
3097a8f
Compare
scottnemes
left a comment
There was a problem hiding this comment.
Works with the basic use case of running queries in the CLI. Can test by setting wait_timeout to something low, waiting that long, then running a query and it will reconnect. But if you enable the keepalive to less than the wait_timeout, then you should not see a reconnect after that time.
3097a8f to
39bb577
Compare
|
Review summary: Small, useful feature, but there are a couple of correctness/edge-case gaps and no tests around the new behavior. Findings
Tests / edge cases
If you want, I can draft a test with a mocked |
39bb577 to
45444e6
Compare
|
Findings
Missing tests / edge cases
If you want, I can draft a small unit test and a safe guard for connection state in |
45444e6 to
0b43960
Compare
|
Findings (ordered by severity)
Missing tests / edge cases
If you want, I can sketch a minimal test scaffold for this behavior. |
The config option is named with "default_" under the [connection] section on the theory that it might one day be configurable by individual connections.
0b43960 to
c03ab3a
Compare
|
Findings (ordered by severity)
Missing tests / edge cases
No security concerns found. If you want, I can sketch a minimal test harness for this without spinning up a real DB connection. |
Description
The config option is named with
default_under the[connection]section on the theory that it might one day be configurable by individual connections.It may be hard to prove when this works/does something useful. But I have the issue of frequent reconnections with some servers, and this feature seems to be provided by MySQL Workbench:
Checklist
changelog.mdfile.AUTHORSfile (or it's already there).