application.yml 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. # 配置端口
  2. server:
  3. port: 30007
  4. compression:
  5. enabled: true
  6. min-response-size: 102400
  7. max-http-request-header-size: 102400
  8. spring:
  9. application:
  10. # 应用名称
  11. name: jnpf-datareport
  12. exclude: com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure #排除自动配置,手动配置druid
  13. datasource:
  14. #数据库类型(可选值 MySQL、SQLServer、Oracle、DM8、KingbaseES、PostgreSQL,请严格按可选值填写)
  15. db-type: MySQL
  16. host: usky-cloud-mysql
  17. port: 3306
  18. username: root
  19. password: yt123456
  20. db-name: jnpf_init
  21. db-schema: #金仓达梦选填
  22. prepare-url: #自定义url
  23. # ===================== 动态多数据源 =====================
  24. dynamic:
  25. primary: master #设置默认的数据源或者数据源组,默认值即为master
  26. strict: true #严格匹配数据源,默认false. true未匹配到指定数据源时抛异常,false使用默认数据源
  27. druid:
  28. # 空闲时执行连接测试
  29. test-while-idle: true
  30. # 连接测试最小间隔
  31. time-between-eviction-runs-millis: 60000
  32. # 获取连接等待3秒 根据网络情况设定
  33. max-wait: 3000
  34. # 初始化4个连接
  35. initial-size: 4
  36. # 最大20个连接
  37. max-active: 20
  38. # 最少保持4个空闲连接
  39. min-idle: 4
  40. # 空闲连接保活, 超过配置的空闲时间会进行连接检查完成保活操作(数据库自身会断开达到空闲时间的连接, 程序使用断开的连接会报错)
  41. keep-alive: true
  42. # 解除注释后Druid连接池打印SQL语句 忽略日志等级配置
  43. #filters: slf4j
  44. slf4j:
  45. statementLogEnabled: true
  46. resultSetLogEnabled: false
  47. connectionLogEnabled: false
  48. dataSourceLogEnabled: false
  49. statementCreateAfterLogEnabled: false
  50. statementCloseAfterLogEnabled: false
  51. statementExecuteAfterLogEnabled: false
  52. #打印SQL替换参数
  53. statementExecutableSqlLogEnable: true
  54. statementPrepareAfterLogEnabled: false
  55. statementPrepareCallAfterLogEnabled: false
  56. statementParameterSetLogEnabled: false
  57. # ===================== Redis配置 =====================
  58. # redis单机模式
  59. data:
  60. redis:
  61. database: 1
  62. host: usky-cloud-redis
  63. port: 6379
  64. password: 123456
  65. timeout: 3000
  66. lettuce: #Lettuce为Redis的Java驱动包
  67. pool:
  68. max-active: 8 # 连接池最大连接数
  69. max-wait: -1ms # 连接池最大阻塞等待时间(使用负值表示没有限制)
  70. min-idle: 0 # 连接池中的最小空闲连接
  71. max-idle: 8 # 连接池中的最大空闲连接
  72. # redis集群模式
  73. # redis:
  74. # cluster:
  75. # nodes:
  76. # - 192.168.0.225:6380
  77. # - 192.168.0.225:6381
  78. # - 192.168.0.225:6382
  79. # - 192.168.0.225:6383
  80. # - 192.168.0.225:6384
  81. # - 192.168.0.225:6385
  82. # password: 123456 # 密码为空时,请将本行注释
  83. # timeout: 3000 # 超时时间(单位:秒)
  84. # lettuce: #Lettuce为Redis的Java驱动包
  85. # pool:
  86. # max-active: 8 # 连接池最大连接数
  87. # max-wait: -1ms # 连接池最大阻塞等待时间(使用负值表示没有限制)
  88. # min-idle: 0 # 连接池中的最小空闲连接
  89. # max-idle: 8 # 连接池中的最大空闲连接
  90. # 日志配置
  91. logging:
  92. config: classpath:logback-spring.xml
  93. level:
  94. #自定义第三方包名日志等级
  95. com.bstek.ureport.console: debug
  96. # 解除注释后Druid连接池打印SQL语句
  97. druid.sql.Statement: debug
  98. # druid.sql.DataSource: debug
  99. # druid.sql.Connection: debug
  100. # druid.sql.ResultSet: debug
  101. log:
  102. level:
  103. # 等级 TRACE,DEBUG,INFO,WARN,ERROR(不区分大小写)
  104. root: ERROR
  105. path: log/${spring.application.name}
  106. config:
  107. #是否开启多租户
  108. MultiTenancy: false
  109. #数据库请求最长执行时间, 防止查询的报表数据过大导致内存溢出, -1不限制 单位:秒
  110. queryTimeout: 5
  111. #最大处理表格数据量
  112. maxRows: 100000
  113. #报表内引用的图片文件夹路径
  114. imgPath:
  115. #Column模式 租户字段
  116. MultiTenantColumn: f_tenant_id
  117. #用户接口地址
  118. userUrl: http://127.0.0.1:30000/api/permission/Users/Current/ReportUserInfo