-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document keepalive for connections using the pool package [Lost connection to MySQL server during query [2013]] #358
Comments
Thanks. Is a connection timeout (=dropping of existing inactive connections) configured in the server? |
Here are some of the variables in the server: wait_timeout: 28800 I don't remember having this error before, and I didn't change the MariaDB (version 10.4.8) configurations since I start using it 8 months ago. What do you suggest? |
Thanks, the timeouts look good to me. There's also Do the server logs give a hint on what's happening here? |
I couldn't get the logs, but found a kind of solution using the "pool" package. It takes care of the connections (in case of several users connecting in a shinyapp) and keep sending small queries so the connection doesn't turn off. I just had to change the connector to
|
This is a very neat trick, thanks for sharing! |
Need to find a place where to document this trick. |
I am constantly getting the error
Lost connection to MySQL server during query [2013]
, which seems to be related to the connection timeout. This happens when I create acon
object and try to use it to collect a table after some time (say, 10 minutes). My connection is created using the commandI also tried to put "timeout = Inf" but with no success. Is the "timeout" argument really working? I am using the github version of DBI and RMariaDB packages.
The text was updated successfully, but these errors were encountered: