You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

66 lines
2.2 KiB
YAML

5 months ago
spring:
datasource:
druid:
driver-class-name: org.postgresql.Driver
url: jdbc:postgresql://192.168.200.152:5432/lobechat
username: postgres
password: uWNZugjBqixf8dxC
initial-size: 10
max-active: 100
min-idle: 5
max-wait: 60000
pool-prepared-statements: true
max-pool-prepared-statement-per-connection-size: 20
time-between-eviction-runs-millis: 60000
min-evictable-idle-time-millis: 300000
#validation-query: SELECT 1 FROM DUAL
test-while-idle: true
test-on-borrow: false
test-on-return: false
stat-view-servlet:
enabled: true
url-pattern: /druid/*
login-username: admin
login-password: oursai
web-stat-filter: # Druid Web统计过滤器配置
enabled: true # 启用Web统计过滤器
session-stat-enable: true # 启用会话统计功能
session-stat-max-count: 1000 # 最大会话统计数量
filter:
stat:
enable: true
log-slow-sql: true
slow-sql-millis: 50
merge-sql: false
wall:
config:
multi-statement-allow: true
data:
redis:
open: true # 是否开启redis缓存 true开启 false关闭
database: 0
#host: 39.174.50.18
host: 127.0.0.1
port: 6379
password: 123456 # 密码(默认为空)
timeout: 6000ms # 连接超时时长(毫秒)
lettuce:
pool:
max-active: 20 # 连接池最大连接数(使用负值表示没有限制)
max-wait: -1ms # 连接池最大阻塞等待时间(使用负值表示没有限制)
max-idle: 10 # 连接池中的最大空闲连接
min-idle: 5 # 连接池中的最小空闲连接
ratelimiter:
enabled: true
redis-address: redis://39.174.50.18:6379
redis-password: 123456
exceptionHandler:
enable: false
logging:
home: logs
pattern:
console: "[%d{yyyy-MM-dd HH:mm:ss.SSS}] %highlight([%-5level]) %green([%15.15thread]) %cyan([%55.55(%logger{50}:%line{5})]) : %msg%n"
file: "[%d{yyyy-MM-dd HH:mm:ss.SSS}] [%-5level] [%15.15thread] [%55.55(%logger{50}:%line{5})] : %msg%n"