mirror of
https://github.com/AuthMe/AuthMeReloaded.git
synced 2024-11-10 04:30:58 +01:00
Enabled cachePrepStmts properties.
This commit is contained in:
parent
b380893847
commit
5187ce152a
@ -104,7 +104,12 @@ public class MySQL implements DataSource {
|
|||||||
ds = new HikariDataSource();
|
ds = new HikariDataSource();
|
||||||
ds.setPoolName("AuthMeMYSQLPool");
|
ds.setPoolName("AuthMeMYSQLPool");
|
||||||
ds.setDriverClassName("com.mysql.jdbc.Driver");
|
ds.setDriverClassName("com.mysql.jdbc.Driver");
|
||||||
ds.setJdbcUrl("jdbc:mysql://" + this.host + ":" + this.port + "/" + this.database + "?rewriteBatchedStatements=true&jdbcCompliantTruncation=false");
|
ds.setJdbcUrl("jdbc:mysql://" + this.host + ":" + this.port + "/" + this.database);
|
||||||
|
ds.addDataSourceProperty("rewriteBatchedStatements", "true");
|
||||||
|
ds.addDataSourceProperty("jdbcCompliantTruncation", "false");
|
||||||
|
ds.addDataSourceProperty("cachePrepStmts", "true");
|
||||||
|
ds.addDataSourceProperty("prepStmtCacheSize", "250");
|
||||||
|
ds.addDataSourceProperty("prepStmtCacheSqlLimit", "2048");
|
||||||
ds.setUsername(this.username);
|
ds.setUsername(this.username);
|
||||||
ds.setPassword(this.password);
|
ds.setPassword(this.password);
|
||||||
ds.setInitializationFailFast(true); // Don't start the plugin if the database is unavailable
|
ds.setInitializationFailFast(true); // Don't start the plugin if the database is unavailable
|
||||||
|
Loading…
Reference in New Issue
Block a user