application.yml 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240
  1. #服务器配置
  2. server:
  3. port: 80
  4. undertow:
  5. # 设置IO线程数, 它主要执行非阻塞的任务,它们会负责多个连接, 默认设置每个CPU核心一个线程
  6. io-threads: 16
  7. # 阻塞任务线程池, 当执行类似servlet请求阻塞操作, undertow会从这个线程池中取得线程,它的值设置取决于系统的负载
  8. worker-threads: 400
  9. # 以下的配置会影响buffer,这些buffer会用于服务器连接的IO操作,有点类似netty的池化内存管理
  10. buffer-size: 1024
  11. # 是否分配的直接内存
  12. direct-buffers: true
  13. spring:
  14. datasource:
  15. driver-class-name: com.mysql.cj.jdbc.Driver
  16. #driver-class-name: org.postgresql.Driver
  17. #driver-class-name: oracle.jdbc.OracleDriver
  18. #driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
  19. druid:
  20. # MySql、PostgreSQL、SqlServer校验
  21. validation-query: select 1
  22. # Oracle校验
  23. #validation-query: select 1 from dual
  24. validation-query-timeout: 2000
  25. initial-size: 5
  26. max-active: 20
  27. min-idle: 5
  28. max-wait: 60000
  29. test-on-borrow: false
  30. test-on-return: false
  31. test-while-idle: true
  32. time-between-eviction-runs-millis: 60000
  33. min-evictable-idle-time-millis: 300000
  34. stat-view-servlet:
  35. enabled: true
  36. login-username: blade
  37. login-password: 1qaz@WSX
  38. web-stat-filter:
  39. enabled: true
  40. url-pattern: /*
  41. exclusions: '*.js,*.gif,*.jpg,*.bmp,*.png,*.css,*.ico,/druid/*'
  42. session-stat-enable: true
  43. session-stat-max-count: 10
  44. # mybatis
  45. mybatis-plus:
  46. mapper-locations: classpath:org/springblade/**/mapper/*Mapper.xml
  47. #实体扫描,多个package用逗号或者分号分隔
  48. typeAliasesPackage: org.springblade.**.entity
  49. #typeEnumsPackage: org.springblade.dashboard.entity.enums
  50. global-config:
  51. # 关闭MP3.0自带的banner
  52. banner: false
  53. db-config:
  54. #主键类型 0:"数据库ID自增", 1:"不操作", 2:"用户输入ID",3:"数字型snowflake", 4:"全局唯一ID UUID", 5:"字符串型snowflake";
  55. id-type: assign_id
  56. #字段策略
  57. insert-strategy: not_null
  58. update-strategy: not_null
  59. select-strategy: not_empty
  60. #驼峰下划线转换
  61. table-underline: true
  62. # 逻辑删除配置
  63. # 逻辑删除全局值(1表示已删除,这也是Mybatis Plus的默认配置)
  64. logic-delete-value: 1
  65. # 逻辑未删除全局值(0表示未删除,这也是Mybatis Plus的默认配置)
  66. logic-not-delete-value: 0
  67. configuration:
  68. map-underscore-to-camel-case: true
  69. cache-enabled: false
  70. #knife4j配置
  71. knife4j:
  72. #启用
  73. enable: true
  74. #基础认证
  75. basic:
  76. enable: false
  77. username: blade
  78. password: blade
  79. #增强配置
  80. setting:
  81. enableSwaggerModels: true
  82. enableDocumentManage: true
  83. enableHost: false
  84. enableHostText: http://localhost
  85. enableRequestCache: true
  86. enableFilterMultipartApis: false
  87. enableFilterMultipartApiMethodType: POST
  88. language: zh-CN
  89. enableFooter: false
  90. enableFooterCustom: true
  91. footerCustomContent: Copyright © 2021 BladeX All Rights Reserved
  92. #swagger公共信息
  93. swagger:
  94. title: BladeX 接口文档系统
  95. description: BladeX 接口文档系统
  96. version: 2.8.0.SNAPSHOT
  97. license: Powered By BladeX
  98. license-url: https://bladex.vip
  99. terms-of-service-url: https://bladex.vip
  100. contact:
  101. name: smallchill
  102. email: smallchill@163.com
  103. url: https://gitee.com/smallc
  104. #flowable配置
  105. flowable:
  106. activity-font-name: \u5B8B\u4F53
  107. label-font-name: \u5B8B\u4F53
  108. annotation-font-name: \u5B8B\u4F53
  109. check-process-definitions: false
  110. database-schema-update: false
  111. #报表配置
  112. report:
  113. enabled: false
  114. database:
  115. provider:
  116. prefix: blade-
  117. #oss默认配置
  118. oss:
  119. enabled: true
  120. name: qiniu
  121. tenant-mode: true
  122. endpoint: http://prt1thnw3.bkt.clouddn.com
  123. access-key: N_Loh1ngBqcJovwiAJqR91Ifj2vgOWHOf8AwBA_h
  124. secret-key: AuzuA1KHAbkIndCU0dB3Zfii2O3crHNODDmpxHRS
  125. bucket-name: bladex
  126. #第三方登陆配置
  127. social:
  128. oauth:
  129. GITHUB:
  130. client-id: 233************
  131. client-secret: 233************************************
  132. redirect-uri: ${social.domain}/oauth/redirect/github
  133. GITEE:
  134. client-id: 233************
  135. client-secret: 233************************************
  136. redirect-uri: ${social.domain}/oauth/redirect/gitee
  137. WECHAT_OPEN:
  138. client-id: 233************
  139. client-secret: 233************************************
  140. redirect-uri: ${social.domain}/oauth/redirect/wechat
  141. QQ:
  142. client-id: 233************
  143. client-secret: 233************************************
  144. redirect-uri: ${social.domain}/oauth/redirect/qq
  145. DINGTALK:
  146. client-id: 233************
  147. client-secret: 233************************************
  148. redirect-uri: ${social.domain}/oauth/redirect/dingtalk
  149. #blade配置
  150. blade:
  151. #token配置
  152. token:
  153. #是否有状态
  154. state: false
  155. #redis序列化方式
  156. redis:
  157. serializer-type: protostuff
  158. #接口配置
  159. api:
  160. #报文加密配置
  161. crypto:
  162. #启用报文加密配置
  163. enabled: false
  164. #使用AesUtil.genAesKey()生成
  165. aes-key: O2BEeIv399qHQNhD6aGW8R8DEj4bqHXm
  166. #使用DesUtil.genDesKey()生成
  167. des-key: jMVCBsFGDQr1USHo
  168. #jackson配置
  169. jackson:
  170. #null自动转空值
  171. null-to-empty: true
  172. #大数字自动转字符串
  173. big-num-to-string: true
  174. #支持text文本请求,与报文加密同时开启
  175. support-text-plain: false
  176. #xss配置
  177. xss:
  178. enabled: true
  179. skip-url:
  180. - /blade-chat/weixin
  181. - /blade-desk/notice/submit
  182. #安全框架配置
  183. secure:
  184. #接口放行
  185. skip-url:
  186. - /blade-test/**
  187. #授权认证配置
  188. auth:
  189. - method: ALL
  190. pattern: /blade-chat/weixin/**
  191. expression: "hasAuth()"
  192. - method: POST
  193. pattern: /blade-desk/dashboard/upload
  194. expression: "hasTimeAuth(9, 17)"
  195. - method: POST
  196. pattern: /blade-desk/dashboard/submit
  197. expression: "hasAnyRole('administrator', 'admin', 'user')"
  198. #基础认证配置
  199. basic:
  200. - method: ALL
  201. pattern: /blade-desk/dashboard/info
  202. username: "blade"
  203. password: "blade"
  204. #动态签名认证配置
  205. sign:
  206. - method: ALL
  207. pattern: /blade-desk/dashboard/sign
  208. crypto: "sha1"
  209. #多终端认证配置
  210. client:
  211. - client-id: sword
  212. path-patterns:
  213. - /blade-sword/**
  214. - client-id: saber
  215. path-patterns:
  216. - /blade-saber/**
  217. #多租户配置
  218. tenant:
  219. #多租户增强
  220. enhance: true
  221. #多租户授权保护
  222. license: false
  223. #动态数据源功能
  224. dynamic-datasource: false
  225. #动态数据源全局扫描
  226. dynamic-global: false
  227. #多租户字段名
  228. column: tenant_id
  229. #排除多租户逻辑
  230. exclude-tables:
  231. - blade_user