Bug #80225 DBMS connection keep-alive interval doesn't work
Submitted: 1 Feb 2016 20:55 Modified: 3 Jun 2016 1:35
Reporter: Joe Grasse (OCA) Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:6.3.6 OS:Any
Assigned to: CPU Architecture:Any

[1 Feb 2016 20:55] Joe Grasse
Description:
The doc for MySQL Workbench says the following.

http://dev.mysql.com/doc/workbench/en/wb-preferences-sql-editor.html

"DBMS connection keep-alive interval (in seconds): [600]. Time interval between sending keep-alive messages to the DBMS."

However keep-alive messages aren't being sent to the DB.

How to repeat:
On DB:

SET GLOBAL interactive_timeout = 10;
SET GLOBAL wait_timeout = 10;

In Workbench:

Go To Edit -> Preferences -> SQL Editor -> DBMS connection keep-alive interval and set to 5.

Connect to DB, wait 15 seconds.
Run Query: SELECT 1;

Result: "Error Code: 2013. Lost connection to MySQL server during query"

Suggested fix:
Send keep-alive messages to DB for the configured interval.
[1 Feb 2016 21:48] MySQL Verification Team
keep-alive error connection lost

Attachment: keepalive.png (image/png, text), 74.29 KiB.

[1 Feb 2016 21:49] MySQL Verification Team
Thank you for the bug report.
[1 Feb 2016 21:51] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=79467 marked as duplicate of this one.
[1 Feb 2016 21:53] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=79575 marked as duplicate of this one.
[18 Feb 2016 10:13] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=80425 marked as duplicate of this one.
[29 Mar 2016 22:30] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=80891 marked as duplicate of this one.
[6 Apr 2016 11:16] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=80970 marked as duplicate of this one.
[6 Apr 2016 11:25] David Beroff
While we certainly do appreciate the consolidation of multiple reports into 
a single thread, it would be even better if we could please simply get the
bug fixed.

The MySQL Workbench is a wonderful tool, but since early December, it's been
rendered effectively useless without having to continually re-login.  Since
the keep-alive functionality worked perfectly prior to December, it would seem
that this would be a relatively easy bug to fix.  Please do so.  Thank you.
[3 Jun 2016 1:35] Philip Olson
Posted by developer:
 
Fixed as of the upcoming MySQL Workbench 6.3.7 release, and here's the changelog entry:

The DBMS connection keep-alive interval option did not function properly.
As a result, Workbench could lose the connection and result in errors
similar to "Error Code: 2013. Lost connection to MySQL server during
query".

Thank you for the bug report.
[5 Jun 2016 19:01] Carl Herkes
Great to hear this will be fixed.  Any estimate on the next release date?
[12 Jun 2016 16:26] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=81820 marked as duplicate of this one.
[17 Jun 2016 10:49] David Beroff
MySQL Workbench 6.3.7 is now available to the public, (THANK YOU!!), but due to
two separate issues, (Bug #81728 and Bug #81905), you may have some difficulty
in installing it.

I found that a good workaround is to go to 
http://dev.mysql.com/downloads/workbench/
skip the Recommended Download(s), skip the 64-bit version, and instead get 
mysql-workbench-community-6.3.7-win32.msi
(Windows (x86, 32-bit), MSI Installer 6.3.7).

I have been testing this installation for this bug, and it works like a champ!

Hope this helps somebody! :-)
[18 Jun 2016 20:29] Carl Herkes
Confirmed.  Installed the 32-bit Windows version.  Came back to my session an hour later and it was still alive.  YES!
[8 Aug 2016 12:45] MySQL Verification Team
http://bugs.mysql.com/bug.php?id=82492 marked as duplicate of this one.