SpringBoot v3.3.3
I added actuator and have the following configuration:
management:
endpoint:
health:
probes:
enabled: true
show-details: always
show-components: always
group:
live:
additional-path: server:/healthz
It provides the following endpoints:
- /actuator/health - returns the full health status
- /healthz - same as above
- /actuator/health/liveness - returns just liveness information
- /actuator/health/readiness - returns just readiness information
This is ok. Now, I want to add additional paths for liveness and readiness probes:
management:
endpoint:
health:
group:
live:
additional-path: server:/healthz
liveness:
additional-path: server:/livez
readiness:
additional-path: server:/readyz
This configurations adds two endpoints: /livez and /readyz.
However, these new endpoints are now returning the full health status, just as the health endpoint.
Expected behaviour is of new additional paths is to return just the probes status.
Comment From: bclozel
I think this is a duplicate of #40268
Comment From: igr
@bclozel
Please note that the setting in the https://github.com/spring-projects/spring-boot/issues/40268 just filters the output and still changes it.
Before, with the first setting, the response of probes is:
{
"status": "UP"
}
After the probes configuration set as specified in the linked ticket, the response is:
{
"status": "UP",
"components": {
"livenessState": {
"status": "UP"
}
}
}
This is NOT the same. If I configure a probe, I would not expect the output to change like this.
Comment From: igr
Using: management.endpoint.health.probes.add-additional-paths=true works as expected. Thanx