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
How to automatically close connections when Script window is closed ? #2998
Comments
|
DBeaver opens connection when you actually connect - e.g. expand connection node in database navigator. SQL script is just one of possible windows which can be additionally opened for that connection. To close a connection just click on Disconnect button in main toolbar. It will close active connection (the one associated with current open editor or current navigator selection). |
|
Hello, I have a similar question, how can I set DBeaver to close all current connections when I exit the application? |
I would love that feature too. |
|
+1 for that last comment |
+1 |
|
Also for the Eclipse plugin, ability to disconnect on events. For instance running DBeaver plugin connected to SQLlite db, and using PyDev to work on script using same DB. If DBeaver is connected, will kill python script for sharing violation. Would be nice if the plugin was watching events, and saw the run preevent and disconnected the SQLlite DB's, so the script could run without errors. |
|
Still any way to do this? I have my db instances running in a docker container, and DBeaver will complain when I close and re-open the application later when the instances aren't running. |
|
Hello I'm planning to work on this. Will try to come up with a pull request. I'll update here if I'm not able to. |
|
Sorry for the huge latency. It seems I'm not able to build the project to start with |
|
Just a heads up, I'm not working on this. Please feel free to take it if you're interested. Sorry for blocking this issue for a long time. |
You are talking about a different problem. When the application is closed, any connections it had will be automatically closed by the operational system. By default, when dbeaver is open, it tries to reconnect to the database which you had editors open. That's the complain you are getting, that during this reconnection, the database is not available. If you don't want it to try to reconnect, change the option mentioned on the stack exchange post ( Window -> Preference -> General -> Editors -> Reopen database editors after restart ). This is not related to the initial question about closing connection to the database when the last script window using it is closed |
|
As a workaround, in Database connection configuration, there's an option under initialization to close idle connections. |


Hello,
When I'm using a MySql script, connecting to the desired serveur and database, after running the script (a select query) if I close the script window, the connection to the database is keeped.
How to autoatically realase the connection when window is closed ?
Some client side items don't work if there's another connection to the database.
Thanks
The text was updated successfully, but these errors were encountered: