Closed null321-jared closed 1 year ago
Hey and thanks for reporting!
Can you try the two versions newer ChatControl? You seem a bit out of date.
Anyways, I run the same SQL and after trying /chc reload and hitting refresh in phpmyadmin, it still only shown two processes. I am trying to reproduce this right? Tested with MySQL.
You can try toggling Hikari key in mysql.yml, disable if you had it on or vice versa and see if that has any effect, although I am not sure if hikari would be the culprit. We did fix this very issue some time ago as I can recall.
Disabling Hikari worked around the issue. So something to look into in the code for that.
Here is my current config:
# Use an external database to store logs, mails and user data (channels, nicks, etc.)?
# If false, then we store these date into your data.db file.
Enabled: true
# Enable the more modern HikariCP connection pool?
# If you have issues, try adding &allowPublicKeyRetrieval=true (or false) at the end of "Line" key,
# as well as changing autoReconnect from true to false. Test various combinations or eventually
# set this key to false as last-resort solution.
Hikari: false
# The host and the port to connect to
Host: localhost:3306
# ADVANCED: The full connector line, do not modify unless you know what you are doing.
# If facing issues try appending &useUnicode=yes&characterEncoding=UTF-8 at the end.
#
# Use 'jdbc:mysql://' if you are running a mysql database.
# Use 'jdbc:mariadb://' if you are running a mariadb database.
Line: jdbc:mariadb://{host}/{database}?autoReconnect=false&useSSL=false
"/version ChatControlRed" - plugin version
10.21.12
Are you using MySQL?
Yes
Are you using BungeeCord?
Yes
Error log (if applicable)
No response
"/chc debug" output (strongly recommended)
debug.zip
Information about the issue/bug
I have 8 servers running with ChatControl Red, and after upgrading from ChatControl Pro to ChatControl red, my MariaDB server has run out of connections. Looking at my MySQL process list, most are ChatControl. This is likely a sign that the connections aren't getting closed correctly, since 8 servers shouldn't have over 200 open connections total.
Here is a snippet of the process list on MariaDB:
As you can see, there are a bunch of sleeping connections. This is a really bad issue because it can break all services that depend on MySQL. To prevent that, I switched ChatControl to its own user, and limited it to 50 connections.