Skip to content
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

[BUG] #412

Closed
quiquelhappy opened this issue Oct 23, 2023 · 1 comment
Closed

[BUG] #412

quiquelhappy opened this issue Oct 23, 2023 · 1 comment

Comments

@quiquelhappy
Copy link

Description

QuickShop is not compatible with up-to-date mysql servers due to the connector being outdated.

Steps to reproduce

https://stackoverflow.com/questions/51016980/java-sql-sqlexception-unknown-system-variable-tx-isolation

Expected Behaviour

be compatible with up-to-date mysql versions

Screenshots

[07:30:00 ERROR]: [QuickShop] Error when setup database
java.lang.RuntimeException: Unable to create a new connection
        at org.maxgamer.quickshop.database.MySQLCore.genConnection(MySQLCore.java:138) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.database.MySQLCore.getConnection0(MySQLCore.java:115) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.database.AbstractDatabaseCore.getConnection(AbstractDatabaseCore.java:76) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.database.DatabaseManager.init(DatabaseManager.java:86) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.database.DatabaseManager.<init>(DatabaseManager.java:76) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.QuickShop.setupDatabase(QuickShop.java:1220) ~[QuickShop-5.1.2.5.jar:?]
        at org.maxgamer.quickshop.QuickShop.onEnable(QuickShop.java:1001) ~[QuickShop-5.1.2.5.jar:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:281) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:?]
        at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:189) ~[paper-1.20.2.jar:git-Paper-245]
        at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:104) ~[paper-1.20.2.jar:git-Paper-245]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:507) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.v1_20_R2.CraftServer.enablePlugin(CraftServer.java:644) ~[paper-1.20.2.jar:git-Paper-245]
        at org.bukkit.craftbukkit.v1_20_R2.CraftServer.enablePlugins(CraftServer.java:555) ~[paper-1.20.2.jar:git-Paper-245]
        at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:627) ~[paper-1.20.2.jar:git-Paper-245]
        at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:424) ~[paper-1.20.2.jar:git-Paper-245]
        at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:308) ~[paper-1.20.2.jar:git-Paper-245]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1086) ~[paper-1.20.2.jar:git-Paper-245]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:315) ~[paper-1.20.2.jar:git-Paper-245]
        at java.lang.Thread.run(Unknown Source) ~[?:?]
Caused by: java.sql.SQLNonTransientConnectionException: Could not create connection to database server. Attempted reconnect 3 times. Giving up.
        at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:111) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:98) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:90) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:64) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:74) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:889) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:814) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:440) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:239) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:188) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at java.sql.DriverManager.getConnection(Unknown Source) ~[java.sql:?]
        at java.sql.DriverManager.getConnection(Unknown Source) ~[java.sql:?]
        at org.maxgamer.quickshop.database.MySQLCore.genConnection(MySQLCore.java:134) ~[QuickShop-5.1.2.5.jar:?]
        ... 18 more
Caused by: com.mysql.cj.exceptions.CJException: Unknown system variable 'transaction_isolation'
        at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]
        at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) ~[?:?]
        at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) ~[?:?]
        at java.lang.reflect.Constructor.newInstanceWithCaller(Unknown Source) ~[?:?]
        at java.lang.reflect.Constructor.newInstance(Unknown Source) ~[?:?]
        at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:62) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:105) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:150) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:128) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.protocol.a.NativeProtocol.checkErrorMessage(NativeProtocol.java:849) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.protocol.a.NativeProtocol.checkErrorMessage(NativeProtocol.java:771) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:701) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:156) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.NativeSession.loadServerVariables(NativeSession.java:445) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.initializePropsFromServer(ConnectionImpl.java:1263) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:852) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:814) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:440) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:239) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:188) ~[mysql-connector-j-8.1.0.jar:8.1.0]
        at java.sql.DriverManager.getConnection(Unknown Source) ~[java.sql:?]
        at java.sql.DriverManager.getConnection(Unknown Source) ~[java.sql:?]
        at org.maxgamer.quickshop.database.MySQLCore.genConnection(MySQLCore.java:134) ~[QuickShop-5.1.2.5.jar:?]
        ... 18 more

/qs paste URL

unable to use

Additional Context

No response

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. Please use English next time.


Title: [BUG]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants