【问题标题】:Custom health actuator properties自定义健康执行器属性
【发布时间】:2020-10-23 16:03:51
【问题描述】:

我正在使用 java springBoot 应用程序 v 1.5.3 我添加了 health actuator 并且工作正常。 我需要做的是调整状态属性并在图片中添加其他 属性名称。 所以我用 globalStatus 代替 status 有没有人知道应该怎么做

谢谢!

【问题讨论】:

    标签: java spring spring-boot spring-boot-actuator actuator


    【解决方案1】:
    info:
        app:
            name: @project.name@
            version: @project.version@
        external-resources:
            services:
                '[service.util]': ${service.util.url}
                another_service: ${service.host}
            database:
                url: ${spring.datasource.url}
                username: ${spring.datasource.username}
        build:
            date: @timestamp@
            commit-sha: ${COMMIT_SHORT_SHA:xxx}
        deployment:
            date: ${DEPLOYMENT_TIME:xxx}
    

    只需将您需要的所有内容放在application.yml 的info 部分下

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-03-10
    • 1970-01-01
    • 2015-07-04
    • 1970-01-01
    • 2015-08-24
    • 1970-01-01
    • 2020-12-19
    相关资源
    最近更新 更多