BanManagement / BanManager

A plugin for Minecraft to manage punishments and moderate more effectively
https://banmanagement.com/
Other
116 stars 90 forks source link

Use of rewriteBatchedStatements disables useServerPrepStmts #955

Closed A248 closed 2 years ago

A248 commented 2 years ago

BanManager sets both useServerPrepStmts and rewriteBatchedStatements to true for the database driver:

https://github.com/BanManagement/BanManager/blob/e7111d1580419eb0c5966fe88f731c0fb4a0a090/common/src/main/java/me/confuser/banmanager/common/BanManagerPlugin.java#L325-L327

However, as described in the driver documentation, rewriteBatchedStatements disables useServerPrepStmts: https://mariadb.com/kb/en/about-mariadb-connector-j/

Thus I'd suggest that you remove rewriteBatchedStatements in favor of useServerPrepStmts, since the two are mutually exclusive and I would guess that useServerPrepStmts is more valuable in terms of performance.

confuser commented 2 years ago

@A248 PRs are welcome, and feel free to join the Discord channel https://discord.gg/59bsgZB

A248 commented 2 years ago

FYI, I'm already in the Discord channel if you'd like to speak to me. I had a discussion with you previously about creating a common standard for punishment plugin data in the form of CSV file.