文章詳情頁(yè)
springboot 如何禁用某項(xiàng)健康檢查
瀏覽:158日期:2023-02-23 17:16:19
springboot 禁用某項(xiàng)健康檢查
management.health.mail.enabledmanagement.health.mongo.enabledmanagement.health.redis.enabledmanagement.health.solr.enabledmanagement.health.elasticsearch.enabled
http://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#production-ready-customizing-endpoints
springboot加es健康檢查問(wèn)題代碼自定義了健康檢查路徑/actuator/health
但是實(shí)際請(qǐng)求的時(shí)候走不到自己的代碼里
會(huì)經(jīng)過(guò)filter攔截掉,攔截之后會(huì)經(jīng)過(guò)調(diào)用es的健康檢查失敗,而返回503
解決辦法:application.yaml里
management endpoints exposure exclude: health排除health,走自己寫(xiě)的健康檢查接口
以上為個(gè)人經(jīng)驗(yàn),希望能給大家一個(gè)參考,也希望大家多多支持好吧啦網(wǎng)。
標(biāo)簽:
Spring
相關(guān)文章:
1. ASP新手必備的基礎(chǔ)知識(shí)2. CentOS郵箱服務(wù)器搭建系列——SMTP服務(wù)器的構(gòu)建( Postfix )3. PHP基礎(chǔ)之生成器4——比較生成器和迭代器對(duì)象4. asp文件用什么軟件編輯5. Vue axios獲取token臨時(shí)令牌封裝案例6. 利用CSS制作3D動(dòng)畫(huà)7. golang中json小談之字符串轉(zhuǎn)浮點(diǎn)數(shù)的操作8. js實(shí)現(xiàn)計(jì)算器功能9. 通過(guò)IEAD+Maven快速搭建SSM項(xiàng)目的過(guò)程(Spring + Spring MVC + Mybatis)10. JS中6個(gè)對(duì)象數(shù)組去重的方法
排行榜

網(wǎng)公網(wǎng)安備