2017-08-11 98 views
2

我使用弹簧启动启动器执行器弹簧启动2.0.0.M3。我启用了两种健康检查:弹簧启动2与执行器

management.health.diskspace.enabled=true 
management.health.mongo.enabled=true 

的healt检查豆类均通过自动配置创建的,但不是HealthMvcEndpointlocalhost:8080/health的回答是404.

我做错了什么?

在此先感谢

编辑:

MHM做执行器项目与无功和webflux? 好吧发现这个问题: https://github.com/spring-projects/spring-boot/issues/7970

回答

1

根据对2.0.0M执行器端点均带有前缀/application本细则,使他们成为/application/health代替。

你也应该能够看到这一切在info日志有关端点,系统重新启动时,您的应用程序

https://docs.spring.io/spring-boot/docs/current-SNAPSHOT/reference/htmlsingle/#production-ready-endpoints

也是一个实际的发行说明一下: https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-2.0.0-M1-Release-Notes#actuator-default-mapping

+0

感谢关于'application'前缀的答案和uppdate,但没有区别端点没有注册。 是的,我知道我会看到有关端点的所有信息,并且日志中没有任何信息。 – SirWayne

+0

从您提供的有关您的问题的信息中,不可能说出可能出现的问题。需要更多关于依赖性,application.properties和应用程序结构的细节。有一件事想起来,虽然;您是否确认了执行器servlet与主应用程序运行相同的端口(8080)。 –

+0

我发现问题执行器不适用于反应性网络通量。只需与春天mvc。 https://github.com/spring-projects/spring-boot/issues/7970 – SirWayne