【Spring Cloud Config 系列】- 健康指示器 / Health Indicator

健康指示器 / Health Indicator

配置服务器附带一个健康指示器,用于检查配置的环境存储库是否工作。
默认情况下会像环境存储库(EnvironmentRepository)请求 application=app、profile=default、label=default 的文件

可以通过配置检查更多的文件

spring:
  cloud:
    config:
      server:
        health:
          repositories:
            myservice:
              label: mylabel
            myservice-dev:
              name: myservice
              profiles: development
          enabled: false  # 可以关闭健康检查    

::: tip tip
此配置没有测试通,不知道是什么意思,没有看到有日志;
:::

Spring Cloud Config 系列 导航目录

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章