- spring:
- datasource:
- driver-class-name: com.MySQL.jdbc.Driver
- type: com.alibaba.druid.pool.DruidDataSource
- filters: stat
- maxActive: 20
- initialSize: 1
- maxWait: 60000
- minIdle:
- timeBetweenEvictionRunsMillis: 60000
- minEvictionRunsMillis: 300000
- validationQuery: select 'x'
- testWhileIdle: true
- testOnBorrow: false
- testOnReturn: false
- poolPreparedStatements: true
- maxOpenPreparedStatements: 20
来源: http://www.bubuko.com/infodetail-2848720.html