|
@@ -11,21 +11,18 @@ spring:
|
|
|
url: jdbc:postgresql://192.168.20.61:8005/pdhw_dev
|
|
|
username: pdhw
|
|
|
password: Citygis1613
|
|
|
- initialSize: 5 # 初始连接数
|
|
|
- minIdle: 5 # 最小空闲连接数
|
|
|
- maxActive: 20 # 最大活跃连接数
|
|
|
- maxWait: 60000 # 获取连接最大等待时间(毫秒)
|
|
|
-
|
|
|
- # 连接有效性检测
|
|
|
- validationQuery: SELECT 1 # 用于检测连接的SQL语句
|
|
|
- testWhileIdle: true # 空闲时检测连接有效性
|
|
|
- testOnBorrow: false # 借出连接时不检测(避免性能损耗)
|
|
|
- testOnReturn: false # 归还连接时不检测
|
|
|
-
|
|
|
- # 连接生命周期管理
|
|
|
- timeBetweenEvictionRunsMillis: 60000 # 检测空闲连接的间隔(毫秒)
|
|
|
- minEvictableIdleTimeMillis: 300000 # 连接最小生存时间(5分钟)
|
|
|
- maxEvictableIdleTimeMillis: 900000 # 连接最大生存时间(15分钟)
|
|
|
+ initial-size: 5
|
|
|
+ min-idle: 5
|
|
|
+ max-active: 20
|
|
|
+ validation-query: SELECT 1
|
|
|
+ test-while-idle: true
|
|
|
+ time-between-eviction-runs-millis: 30000
|
|
|
+ min-evictable-idle-time-millis: 60000
|
|
|
+ filters: stat,wall
|
|
|
+ connection-properties: druid.mysql.usePingMethod=false
|
|
|
+ stat-view-servlet:
|
|
|
+ enabled: true
|
|
|
+ url-pattern: /druid/*
|
|
|
# redis ??
|
|
|
redis:
|
|
|
database: 0
|