From c4eb641d9c2facb880895b1fa7937415829735b2 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期一, 17 五月 2021 16:36:07 +0800
Subject: [PATCH] fix 修复swagger开关无法控制关闭问题

---
 ruoyi-admin/src/main/resources/application.yml |  304 ++++++++++++++++++++++++++++++++++++++++----------
 1 files changed, 241 insertions(+), 63 deletions(-)

diff --git a/ruoyi-admin/src/main/resources/application.yml b/ruoyi-admin/src/main/resources/application.yml
index 4c9aa84..b034d99 100644
--- a/ruoyi-admin/src/main/resources/application.yml
+++ b/ruoyi-admin/src/main/resources/application.yml
@@ -1,42 +1,64 @@
 # 椤圭洰鐩稿叧閰嶇疆
 ruoyi:
   # 鍚嶇О
-  name: RuoYi
+  name: RuoYi-Vue-Plus
   # 鐗堟湰
-  version: 3.0.0
+  version: ${ruoyi-vue-plus.version}
   # 鐗堟潈骞翠唤
-  copyrightYear: 2019
+  copyrightYear: 2021
   # 瀹炰緥婕旂ず寮�鍏�
   demoEnabled: true
-  # 鏂囦欢璺緞 绀轰緥锛� Windows閰嶇疆D:/ruoyi/uploadPath锛孡inux閰嶇疆 /home/ruoyi/uploadPath锛�
-  profile: D:/ruoyi/uploadPath
+  # 鏂囦欢璺緞,浣跨敤jvm绯荤粺鍙橀噺,鍏煎windows鍜宭inux;
+  profile: ${user.dir}/ruoyi/uploadPath
   # 鑾峰彇ip鍦板潃寮�鍏�
   addressEnabled: false
+
+captcha:
+  # 楠岃瘉鐮佺被鍨� math 鏁扮粍璁$畻 char 瀛楃楠岃瘉
+  type: math
+  # line 绾挎骞叉壈 circle 鍦嗗湀骞叉壈 shear 鎵洸骞叉壈
+  category: circle
+  # 鏁板瓧楠岃瘉鐮佷綅鏁�
+  numberLength: 1
+  # 瀛楃楠岃瘉鐮侀暱搴�
+  charLength: 4
 
 # 寮�鍙戠幆澧冮厤缃�
 server:
   # 鏈嶅姟鍣ㄧ殑HTTP绔彛锛岄粯璁や负8080
-  port: 8081
+  port: 8080
   servlet:
     # 搴旂敤鐨勮闂矾寰�
     context-path: /
+  # undertow 閰嶇疆
   undertow:
-    # 璁剧疆IO绾跨▼鏁�, 瀹冧富瑕佹墽琛岄潪闃诲鐨勪换鍔�,瀹冧滑浼氳礋璐e涓繛鎺�, 榛樿璁剧疆姣忎釜CPU鏍稿績涓�涓嚎绋�
-    io-threads: 8
-    # 闃诲浠诲姟绾跨▼姹�, 褰撴墽琛岀被浼約ervlet璇锋眰闃诲鎿嶄綔, undertow浼氫粠杩欎釜绾跨▼姹犱腑鍙栧緱绾跨▼,瀹冪殑鍊艰缃彇鍐充簬绯荤粺鐨勮礋杞�
-    worker-threads: 256
+    # HTTP post鍐呭鐨勬渶澶уぇ灏忋�傚綋鍊间负-1鏃讹紝榛樿鍊间负澶у皬鏄棤闄愮殑
+    max-http-post-size: -1
     # 浠ヤ笅鐨勯厤缃細褰卞搷buffer,杩欎簺buffer浼氱敤浜庢湇鍔″櫒杩炴帴鐨処O鎿嶄綔,鏈夌偣绫讳技netty鐨勬睜鍖栧唴瀛樼鐞�
     # 姣忓潡buffer鐨勭┖闂村ぇ灏�,瓒婂皬鐨勭┖闂磋鍒╃敤瓒婂厖鍒�
     buffer-size: 512
     # 鏄惁鍒嗛厤鐨勭洿鎺ュ唴瀛�
     direct-buffers: true
-
+    threads:
+      # 璁剧疆IO绾跨▼鏁�, 瀹冧富瑕佹墽琛岄潪闃诲鐨勪换鍔�,瀹冧滑浼氳礋璐e涓繛鎺�, 榛樿璁剧疆姣忎釜CPU鏍稿績涓�涓嚎绋�
+      io: 8
+      # 闃诲浠诲姟绾跨▼姹�, 褰撴墽琛岀被浼約ervlet璇锋眰闃诲鎿嶄綔, undertow浼氫粠杩欎釜绾跨▼姹犱腑鍙栧緱绾跨▼,瀹冪殑鍊艰缃彇鍐充簬绯荤粺鐨勮礋杞�
+      worker: 256
+#  # tomcat 閰嶇疆
+#  tomcat:
+#    # tomcat鐨刄RI缂栫爜
+#    uri-encoding: UTF-8
+#    # tomcat鏈�澶х嚎绋嬫暟锛岄粯璁や负200
+#    max-threads: 500
+#    # Tomcat鍚姩鍒濆鍖栫殑绾跨▼鏁帮紝榛樿鍊�25
+#    min-spare-threads: 30
 
 # 鏃ュ織閰嶇疆
 logging:
   level:
-    com.ruoyi: debug
+    com.ruoyi: @logging.level@
     org.springframework: warn
+  config: classpath:logback.xml
 
 # Spring閰嶇疆
 spring:
@@ -44,82 +66,238 @@
   messages:
     # 鍥介檯鍖栬祫婧愭枃浠惰矾寰�
     basename: i18n/messages
-  profiles: 
-    active: dev
+  profiles:
+    active: @profiles.active@
   # 鏂囦欢涓婁紶
   servlet:
-     multipart:
-       # 鍗曚釜鏂囦欢澶у皬
-       max-file-size:  10MB
-       # 璁剧疆鎬讳笂浼犵殑鏂囦欢澶у皬
-       max-request-size:  20MB
+    multipart:
+      # 鍗曚釜鏂囦欢澶у皬
+      max-file-size: 10MB
+      # 璁剧疆鎬讳笂浼犵殑鏂囦欢澶у皬
+      max-request-size: 20MB
   # 鏈嶅姟妯″潡
   devtools:
     restart:
       # 鐑儴缃插紑鍏�
       enabled: true
+  # 涓巚ue鏁村悎閮ㄧ讲浣跨敤
+  thymeleaf:
+    # 灏嗙郴缁熸ā鏉挎斁缃埌鏈�鍓嶉潰 鍚﹀垯浼氫笌 springboot-admin 椤甸潰鍐茬獊
+    template-resolver-order: 1
 
 # token閰嶇疆
 token:
-    # 浠ょ墝鑷畾涔夋爣璇�
-    header: Authorization
-    # 浠ょ墝瀵嗛挜
-    secret: abcdefghijklmnopqrstuvwxyz
-    # 浠ょ墝鏈夋晥鏈燂紙榛樿30鍒嗛挓锛�
-    expireTime: 30
+  # 浠ょ墝鑷畾涔夋爣璇�
+  header: Authorization
+  # 浠ょ墝瀵嗛挜
+  secret: abcdefghijklmnopqrstuvwxyz
+  # 浠ょ墝鏈夋晥鏈燂紙榛樿30鍒嗛挓锛�
+  expireTime: 30
 
-# MyBatis閰嶇疆
+# MyBatisPlus閰嶇疆
+# https://baomidou.com/config/
 mybatis-plus:
-  mapper-locations: classpath*:mapper/**/*Mapper.xml
-  #瀹炰綋鎵弿锛屽涓猵ackage鐢ㄩ�楀彿鎴栬�呭垎鍙峰垎闅�
+  mapperPackage: com.ruoyi.**.mapper
+  # 瀵瑰簲鐨� XML 鏂囦欢浣嶇疆
+  mapperLocations: classpath*:mapper/**/*Mapper.xml
+  # 瀹炰綋鎵弿锛屽涓猵ackage鐢ㄩ�楀彿鎴栬�呭垎鍙峰垎闅�
   typeAliasesPackage: com.ruoyi.**.domain
+  # 閽堝 typeAliasesPackage锛屽鏋滈厤缃簡璇ュ睘鎬э紝鍒欎粎浠呬細鎵弿璺緞涓嬩互璇ョ被浣滀负鐖剁被鐨勫煙瀵硅薄
+  #typeAliasesSuperType: Class<?>
+  # 濡傛灉閰嶇疆浜嗚灞炴�э紝SqlSessionFactoryBean 浼氭妸璇ュ寘涓嬮潰鐨勭被娉ㄥ唽涓哄搴旂殑 TypeHandler
+  #typeHandlersPackage: null
+  # 濡傛灉閰嶇疆浜嗚灞炴�э紝浼氬皢璺緞涓嬬殑鏋氫妇绫昏繘琛屾敞鍏ワ紝璁╁疄浣撶被瀛楁鑳藉绠�鍗曞揩鎹风殑浣跨敤鏋氫妇灞炴��
+  #typeEnumsPackage: null
+  # 鍚姩鏃舵槸鍚︽鏌� MyBatis XML 鏂囦欢鐨勫瓨鍦紝榛樿涓嶆鏌�
+  checkConfigLocation: false
+  # 閫氳繃璇ュ睘鎬у彲鎸囧畾 MyBatis 鐨勬墽琛屽櫒锛孧yBatis 鐨勬墽琛屽櫒鎬诲叡鏈変笁绉嶏細
+  # SIMPLE锛氳鎵ц鍣ㄧ被鍨嬩笉鍋氱壒娈婄殑浜嬫儏锛屼负姣忎釜璇彞鐨勬墽琛屽垱寤轰竴涓柊鐨勯澶勭悊璇彞锛圥reparedStatement锛�
+  # REUSE锛氳鎵ц鍣ㄧ被鍨嬩細澶嶇敤棰勫鐞嗚鍙ワ紙PreparedStatement锛�
+  # BATCH锛氳鎵ц鍣ㄧ被鍨嬩細鎵归噺鎵ц鎵�鏈夌殑鏇存柊璇彞
+  executorType: SIMPLE
+  # 鎸囧畾澶栭儴鍖� MyBatis Properties 閰嶇疆锛岄�氳繃璇ラ厤缃彲浠ユ娊绂婚厤缃紝瀹炵幇涓嶅悓鐜鐨勯厤缃儴缃�
+  configurationProperties: null
   configuration:
-    map-underscore-to-camel-case: true
-    cache-enabled: true
+    # 鑷姩椹煎嘲鍛藉悕瑙勫垯锛坈amel case锛夋槧灏�
+    # 濡傛灉鎮ㄧ殑鏁版嵁搴撳懡鍚嶇鍚堣鍒欐棤闇�浣跨敤 @TableField 娉ㄨВ鎸囧畾鏁版嵁搴撳瓧娈靛悕
+    mapUnderscoreToCamelCase: true
+    # 榛樿鏋氫妇澶勭悊绫�,濡傛灉閰嶇疆浜嗚灞炴��,鏋氫妇灏嗙粺涓�浣跨敤鎸囧畾澶勭悊鍣ㄨ繘琛屽鐞�
+    # org.apache.ibatis.type.EnumTypeHandler : 瀛樺偍鏋氫妇鐨勫悕绉�
+    # org.apache.ibatis.type.EnumOrdinalTypeHandler : 瀛樺偍鏋氫妇鐨勭储寮�
+    # com.baomidou.mybatisplus.extension.handlers.MybatisEnumTypeHandler : 鏋氫妇绫婚渶瑕佸疄鐜癐Enum鎺ュ彛鎴栧瓧娈垫爣璁癅EnumValue娉ㄨВ.
+    defaultEnumTypeHandler: org.apache.ibatis.type.EnumTypeHandler
+    # 褰撹缃负 true 鐨勬椂鍊欙紝鎳掑姞杞界殑瀵硅薄鍙兘琚换浣曟噿灞炴�у叏閮ㄥ姞杞斤紝鍚﹀垯锛屾瘡涓睘鎬ч兘鎸夐渶鍔犺浇銆傞渶瑕佸拰 lazyLoadingEnabled 涓�璧蜂娇鐢ㄣ��
+    aggressiveLazyLoading: true
+    # MyBatis 鑷姩鏄犲皠绛栫暐
+    # NONE锛氫笉鍚敤鑷姩鏄犲皠
+    # PARTIAL锛氬彧瀵归潪宓屽鐨� resultMap 杩涜鑷姩鏄犲皠
+    # FULL锛氬鎵�鏈夌殑 resultMap 閮借繘琛岃嚜鍔ㄦ槧灏�
+    autoMappingBehavior: PARTIAL
+    # MyBatis 鑷姩鏄犲皠鏃舵湭鐭ュ垪鎴栨湭鐭ュ睘鎬у鐞嗙瓥
+    # NONE锛氫笉鍋氫换浣曞鐞� (榛樿鍊�)
+    # WARNING锛氫互鏃ュ織鐨勫舰寮忔墦鍗扮浉鍏宠鍛婁俊鎭�
+    # FAILING锛氬綋浣滄槧灏勫け璐ュ鐞嗭紝骞舵姏鍑哄紓甯稿拰璇︾粏淇℃伅
+    autoMappingUnknownColumnBehavior: NONE
+    # Mybatis涓�绾х紦瀛橈紝榛樿涓� SESSION
+    # SESSION session绾у埆缂撳瓨锛屽悓涓�涓猻ession鐩稿悓鏌ヨ璇彞涓嶄細鍐嶆鏌ヨ鏁版嵁搴�
+    # STATEMENT 鍏抽棴涓�绾х紦瀛�
+    localCacheScope: SESSION
+    # 寮�鍚疢ybatis浜岀骇缂撳瓨锛岄粯璁や负 true
+    cacheEnabled: true
   global-config:
-    banner: false
-    #鍒锋柊mapper 璋冭瘯绁炲櫒
-    refresh: true
-    db-config:
-      #涓婚敭绫诲瀷  0:"鏁版嵁搴揑D鑷", 1:"鐢ㄦ埛杈撳叆ID",2:"鍏ㄥ眬鍞竴ID (鏁板瓧绫诲瀷鍞竴ID)", 3:"鍏ㄥ眬鍞竴ID UUID";
-      id-type: auto
-      #瀛楁绛栫暐 0:"蹇界暐鍒ゆ柇",1:"闈� NULL 鍒ゆ柇"),2:"闈炵┖鍒ゆ柇"
-      field-strategy: not_empty
-      #椹煎嘲涓嬪垝绾胯浆鎹�
-      db-column-underline: true
-      #鏁版嵁搴撳ぇ鍐欎笅鍒掔嚎杞崲
-      #capital-mode: true
-      #搴忓垪鎺ュ彛瀹炵幇绫婚厤缃�
-      #key-generator: com.baomidou.springboot.xxx
-      #閫昏緫鍒犻櫎閰嶇疆
-      logic-delete-value: 1
-      logic-not-delete-value: 0
-      #鏁版嵁搴撶被鍨�
-      db-type: mysql
-    #鑷畾涔塖QL娉ㄥ叆鍣�
-    #sql-injector: com.baomidou.mybatisplus.mapper.LogicSqlInjector
-    #鑷畾涔夊~鍏呯瓥鐣ユ帴鍙e疄鐜�
-    #meta-object-handler: com.baomidou.springboot.xxx
-
-# PageHelper鍒嗛〉鎻掍欢
-pagehelper: 
-  helperDialect: mysql
-  reasonable: true
-  supportMethodsArguments: true
-  params: count=countSql 
+    # 鏄惁鎵撳嵃 Logo banner
+    banner: true
+    # 鏄惁鍒濆鍖� SqlRunner
+    enableSqlRunner: false
+    dbConfig:
+      # 涓婚敭绫诲瀷
+      # AUTO 鏁版嵁搴揑D鑷
+      # NONE 绌�
+      # INPUT 鐢ㄦ埛杈撳叆ID
+      # ASSIGN_ID 鍏ㄥ眬鍞竴ID
+      # ASSIGN_UUID 鍏ㄥ眬鍞竴ID UUID
+      idType: AUTO
+      # 琛ㄥ悕鍓嶇紑
+      tablePrefix: null
+      # 瀛楁 format,渚�: %s,(瀵逛富閿棤鏁�)
+      columnFormat: null
+      # 琛ㄥ悕鏄惁浣跨敤椹煎嘲杞笅鍒掔嚎鍛藉悕,鍙琛ㄥ悕鐢熸晥
+      tableUnderline: true
+      # 澶у啓鍛藉悕,瀵硅〃鍚嶅拰瀛楁鍚嶅潎鐢熸晥
+      capitalMode: false
+      # 鍏ㄥ眬鐨別ntity鐨勯�昏緫鍒犻櫎瀛楁灞炴�у悕
+      logicDeleteField: null
+      # 閫昏緫宸插垹闄ゅ��
+      logicDeleteValue: 2
+      # 閫昏緫鏈垹闄ゅ��
+      logicNotDeleteValue: 0
+      # 瀛楁楠岃瘉绛栫暐涔� insert,鍦� insert 鐨勬椂鍊欑殑瀛楁楠岃瘉绛栫暐
+      # IGNORED 蹇界暐鍒ゆ柇
+      # NOT_NULL 闈濶ULL鍒ゆ柇
+      # NOT_EMPTY 闈炵┖鍒ゆ柇(鍙瀛楃涓茬被鍨嬪瓧娈�,鍏朵粬绫诲瀷瀛楁渚濈劧涓洪潪NULL鍒ゆ柇)
+      # DEFAULT 榛樿鐨�,涓�鑸彧鐢ㄤ簬娉ㄨВ閲�
+      # NEVER 涓嶅姞鍏� SQL
+      insertStrategy: NOT_EMPTY
+      # 瀛楁楠岃瘉绛栫暐涔� update,鍦� update 鐨勬椂鍊欑殑瀛楁楠岃瘉绛栫暐
+      updateStrategy: NOT_EMPTY
+      # 瀛楁楠岃瘉绛栫暐涔� select,鍦� select 鐨勬椂鍊欑殑瀛楁楠岃瘉绛栫暐鏃� wrapper 鏍规嵁鍐呴儴 entity 鐢熸垚鐨� where 鏉′欢
+      selectStrategy: NOT_EMPTY
 
 # Swagger閰嶇疆
 swagger:
   # 鏄惁寮�鍚痵wagger
   enabled: true
-  # 璇锋眰鍓嶇紑
-  pathMapping: /dev-api
+  # 鏍囬
+  title: '鏍囬锛歊uoYi-Vue-Plus鍚庡彴绠$悊绯荤粺_鎺ュ彛鏂囨。'
+  # 鎻忚堪
+  description: '鎻忚堪锛氱敤浜庣鐞嗛泦鍥㈡棗涓嬪叕鍙哥殑浜哄憳淇℃伅,鍏蜂綋鍖呮嫭XXX,XXX妯″潡...'
+  # 鐗堟湰
+  version: '鐗堟湰鍙�: ${ruoyi-vue-plus.version}'
+  # 浣滆�呬俊鎭�
+  contact:
+    name: Lion Li
+    email: crazylionli@163.com
+    url: https://gitee.com/JavaLionLi/RuoYi-Vue-Plus
 
 # 闃叉XSS鏀诲嚮
-xss: 
+xss:
   # 杩囨护寮�鍏�
   enabled: true
   # 鎺掗櫎閾炬帴锛堝涓敤閫楀彿鍒嗛殧锛�
   excludes: /system/notice/*
   # 鍖归厤閾炬帴
   urlPatterns: /system/*,/monitor/*,/tool/*
+
+# 鍏ㄥ眬绾跨▼姹犵浉鍏抽厤缃�
+thread-pool:
+  # 鏄惁寮�鍚嚎绋嬫睜
+  enabled: false
+  # 鏍稿績绾跨▼姹犲ぇ灏�
+  corePoolSize: 8
+  # 鏈�澶у彲鍒涘缓鐨勭嚎绋嬫暟
+  maxPoolSize: 16
+  # 闃熷垪鏈�澶ч暱搴�
+  queueCapacity: 128
+  # 绾跨▼姹犵淮鎶ょ嚎绋嬫墍鍏佽鐨勭┖闂叉椂闂�
+  keepAliveSeconds: 300
+  # 绾跨▼姹犲鎷掔粷浠诲姟(鏃犵嚎绋嬪彲鐢�)鐨勫鐞嗙瓥鐣�
+  # CallerRunsPolicy 绛夊緟
+  # DiscardOldestPolicy 鏀惧純鏈�鏃х殑
+  # DiscardPolicy 涓㈠純
+  # AbortPolicy 涓
+  rejectedExecutionHandler: CallerRunsPolicy
+
+# feign 鐩稿叧閰嶇疆
+feign:
+  package: com.ruoyi.**.feign
+  # 寮�鍚帇缂�
+  compression:
+    request:
+      enabled: true
+    response:
+      enabled: true
+  okhttp:
+    enabled: true
+  hystrix:
+    enabled: true
+
+--- # 瀹氭椂浠诲姟閰嶇疆
+spring:
+  quartz:
+    scheduler-name: RuoyiScheduler
+    startup-delay: 1s
+    overwrite-existing-jobs: true
+    auto-startup: true
+    job-store-type: jdbc
+    properties:
+      org:
+        quartz:
+          # Scheduler 鐩稿叧閰嶇疆
+          scheduler:
+            instanceName: RuoyiScheduler
+            instanceId: AUTO
+          # 绾跨▼姹犵浉鍏抽厤缃�
+          threadPool:
+            class: org.quartz.simpl.SimpleThreadPool
+            threadCount: 20
+            threadPriority: 5
+          # JobStore 闆嗙兢閰嶇疆
+          jobStore:
+            class: org.quartz.impl.jdbcjobstore.JobStoreTX
+            isClustered: true
+            clusterCheckinInterval: 15000
+            txIsolationLevelSerializable: true
+            misfireThreshold: 60000
+            tablePrefix: QRTZ_
+            # sqlserver 鍚敤
+            # selectWithLockSQL: SELECT * FROM {0}LOCKS UPDLOCK WHERE LOCK_NAME = ?
+
+--- # 鐩戞帶閰嶇疆
+spring:
+  application:
+    name: ruoyi-vue-plus
+  boot:
+    admin:
+      # Spring Boot Admin Client 瀹㈡埛绔殑鐩稿叧閰嶇疆
+      client:
+        # 璁剧疆 Spring Boot Admin Server 鍦板潃
+        url: http://localhost:${server.port}${spring.boot.admin.context-path}
+        instance:
+          prefer-ip: true # 娉ㄥ唽瀹炰緥鏃讹紝浼樺厛浣跨敤 IP
+      #        username: ruoyi
+      #        password: 123456
+      # Spring Boot Admin Server 鏈嶅姟绔殑鐩稿叧閰嶇疆
+      context-path: /admin # 閰嶇疆 Spring
+
+# Actuator 鐩戞帶绔偣鐨勯厤缃」
+management:
+  endpoints:
+    web:
+      # Actuator 鎻愪緵鐨� API 鎺ュ彛鐨勬牴鐩綍銆傞粯璁や负 /actuator
+      base-path: /actuator
+      exposure:
+        # 闇�瑕佸紑鏀剧殑绔偣銆傞粯璁ゅ�煎彧鎵撳紑 health 鍜� info 涓や釜绔偣銆傞�氳繃璁剧疆 * 锛屽彲浠ュ紑鏀炬墍鏈夌鐐广��
+        include: '*'
+  endpoint:
+    logfile:
+      external-file: ./logs/sys-console.log

--
Gitblit v1.9.3