Bus Endpoints
Spring Cloud Bus provides three endpoints, /actuator/busrefresh, /actutator/busshutdown and /actuator/busenv
that correspond to individual actuator endpoints in Spring Cloud Commons,
/actuator/refresh, /actuator/shutdown, and /actuator/env respectively.
Bus Refresh Endpoint
The /actuator/busrefresh endpoint clears the RefreshScope cache and rebinds
@ConfigurationProperties. See the Refresh Scope documentation for
more information.
To expose the /actuator/busrefresh endpoint, you need to add following configuration to your
application:
management.endpoints.web.exposure.include=busrefresh
Bus Env Endpoint
The /actuator/busenv endpoint updates each instances environment with the specified
key/value pair across multiple instances.
To expose the /actuator/busenv endpoint, you need to add following configuration to your
application:
management.endpoints.web.exposure.include=busenv
The /actuator/busenv endpoint accepts POST requests with the following shape:
{
"name": "key1",
"value": "value1"
}
Bus Shutdown Endpoint
The /actuator/busshutdown shuts down the application gracefully.
To expose the /actuator/busshutdown endpoint, you need to add following configuration to your
application:
management.endpoints.web.exposure.include=busshutdown
You can make a request to the busshutdown endpoint by issuing a POST request.
If you would like to target a specific application you can issue a POST request to /busshutdown and optionally
specify the bus id:
$ curl -X POST http://localhost:8080/actuator/busshutdown
You can also target a specific application instance by specifying the bus id:
$ curl -X POST http://localhost:8080/actuator/busshutdown/busid:123