Hikari连接池的一个优化配置文件

Hikari号称最快的连接池,这边贴一个github上找到的一个宣称最大化MySQL性能的配置文件(db.properties),供各位看官查看

  1 #inner
  2 jdbcUrl=jdbc:mysql://192.168.2.7:3306/lxd?useSSL=false
  3 username=root
  4 password=root
  5 
  6 #pool properties
  7 connectionTimeout=60000
  8 idleTimeout=600000
  9 minimumIdle=1
 10 maximumPoolSize=50
 11 #poolname
 12 
 13 
 14 
 15 #datasource properties, max performance
 16 #该项极大影响插入效率
 17 dataSource.cachePrepStmts=true
 18 dataSource.prepStmtCacheSize=250
 19 dataSource.prepStmtCacheSqlLimit=2048
 20 dataSource.useServerPrepStmts=true
 21 dataSource.useLocalSessionState=true
 22 dataSource.rewriteBatchedStatements=true
 23 dataSource.cacheResultSetMetadata=true
 24 #dataSource.cacheServerConfiguration=true
 25 #dataSource.elideSetAutoCommits=true
 26 dataSource.maintainTimeStats=false
 27 dataSource.useCursorFetch=true
原文地址:https://www.cnblogs.com/marshwinter/p/13713331.html