application-druid.yml 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. # 数据源配置
  2. spring:
  3. # redis 配置
  4. redis:
  5. # 地址 localhost
  6. host: 127.0.0.1
  7. # 端口,默认为6379
  8. port: 6379
  9. # 数据库索引
  10. database: 0
  11. # 密码
  12. password:
  13. # password:
  14. # 连接超时时间
  15. timeout: 10s
  16. lettuce:
  17. pool:
  18. # 连接池中的最小空闲连接
  19. min-idle: 0
  20. # 连接池中的最大空闲连接
  21. max-idle: 8
  22. # 连接池的最大数据库连接数
  23. max-active: 8
  24. # #连接池最大阻塞等待时间(使用负值表示没有限制)
  25. max-wait: -1ms
  26. datasource:
  27. # clickhouse:
  28. # type: com.alibaba.druid.pool.DruidDataSource
  29. # driverClassName: com.clickhouse.jdbc.ClickHouseDriver
  30. # url: jdbc:clickhouse://cc-2vc8zzo26w0l7m2l6.public.clickhouse.ads.aliyuncs.com/sop?compress=0&use_server_time_zone=true&use_client_time_zone=false&timezone=Asia/Shanghai
  31. # username: rt_2024
  32. # password: Yzx_19860213
  33. # initialSize: 10
  34. # maxActive: 100
  35. # minIdle: 10
  36. # maxWait: 6000
  37. mysql:
  38. type: com.alibaba.druid.pool.DruidDataSource
  39. driverClassName: com.mysql.cj.jdbc.Driver
  40. druid:
  41. # 主库数据源
  42. master:
  43. url: jdbc:mysql://cq-cdb-95qvu08p.sql.tencentcdb.com:63998/fs_his?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
  44. username: root
  45. password: Rtyy_2023
  46. # 从库数据源
  47. slave:
  48. # 从数据源开关/默认关闭
  49. enabled: false
  50. url:
  51. username:
  52. password:
  53. # 初始连接数
  54. initialSize: 5
  55. # 最小连接池数量
  56. minIdle: 10
  57. # 最大连接池数量
  58. maxActive: 20
  59. # 配置获取连接等待超时的时间
  60. maxWait: 60000
  61. # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
  62. timeBetweenEvictionRunsMillis: 60000
  63. # 配置一个连接在池中最小生存的时间,单位是毫秒
  64. minEvictableIdleTimeMillis: 300000
  65. # 配置一个连接在池中最大生存的时间,单位是毫秒
  66. maxEvictableIdleTimeMillis: 900000
  67. # 配置检测连接是否有效
  68. validationQuery: SELECT 1 FROM DUAL
  69. testWhileIdle: true
  70. testOnBorrow: false
  71. testOnReturn: false
  72. webStatFilter:
  73. enabled: true
  74. statViewServlet:
  75. enabled: true
  76. # 设置白名单,不填则允许所有访问
  77. allow:
  78. url-pattern: /druid/*
  79. # 控制台管理用户名和密码
  80. login-username: fs
  81. login-password: 123456
  82. filter:
  83. stat:
  84. enabled: true
  85. # 慢SQL记录
  86. log-slow-sql: true
  87. slow-sql-millis: 1000
  88. merge-sql: true
  89. wall:
  90. config:
  91. multi-statement-allow: true
  92. sop:
  93. type: com.alibaba.druid.pool.DruidDataSource
  94. driverClassName: com.mysql.cj.jdbc.Driver
  95. druid:
  96. # 主库数据源
  97. master:
  98. url: jdbc:mysql://gz-cdb-of55khc9.sql.tencentcdb.com:23620/fs_his_sop?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
  99. username: root
  100. password: Rtyy_2023
  101. # 初始连接数
  102. initialSize: 5
  103. # 最小连接池数量
  104. minIdle: 10
  105. # 最大连接池数量
  106. maxActive: 20
  107. # 配置获取连接等待超时的时间
  108. maxWait: 60000
  109. # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
  110. timeBetweenEvictionRunsMillis: 60000
  111. # 配置一个连接在池中最小生存的时间,单位是毫秒
  112. minEvictableIdleTimeMillis: 300000
  113. # 配置一个连接在池中最大生存的时间,单位是毫秒
  114. maxEvictableIdleTimeMillis: 900000
  115. # 配置检测连接是否有效
  116. validationQuery: SELECT 1 FROM DUAL
  117. testWhileIdle: true
  118. testOnBorrow: false
  119. testOnReturn: false
  120. webStatFilter:
  121. enabled: true
  122. statViewServlet:
  123. enabled: true
  124. # 设置白名单,不填则允许所有访问
  125. allow:
  126. url-pattern: /druid/*
  127. # 控制台管理用户名和密码
  128. login-username: fs
  129. login-password: 123456
  130. filter:
  131. stat:
  132. enabled: true
  133. # 慢SQL记录
  134. log-slow-sql: true
  135. slow-sql-millis: 1000
  136. merge-sql: true
  137. wall:
  138. config:
  139. multi-statement-allow: true
  140. rocketmq:
  141. name-server: rmq-1243b25nj.rocketmq.gz.public.tencenttdmq.com:8080 # RocketMQ NameServer 地址
  142. producer:
  143. group: my-producer-group
  144. access-key: ak1243b25nj17d4b2dc1a03 # 替换为实际的 accessKey
  145. secret-key: sk08a7ea1f9f4b0237 # 替换为实际的 secretKey
  146. consumer:
  147. group: voice-group
  148. access-key: ak1243b25nj17d4b2dc1a03 # 替换为实际的 accessKey
  149. secret-key: sk08a7ea1f9f4b0237 # 替换为实际的 secretKey