Springboot2.0 springconfig配置中心 bus-refresh发送给config-client为404

在做spring cloud config配置中心时,给config-server和config-client添加actuator、amqp依赖,也都在yml文件中暴露bus-refresh,在需要更新的类也加入@RefreshScope。
现在是给config-server发送actuator/bus-refresh可以更新客户端配置信息,而无法给config-client发送actuator/bus-refresh,相应为404。
请大佬求解!!!
在config-server中有打印/actuator/bus-refresh],methods=[POST]信息
而在config-client中没有

我也出现了这个问题,后来发现是spring-cloud-bus-amqp版本不对,一开始这样不行:

<dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    <version>2.2.0.M3</version>
</dependency>

没有接口:

没有接口

后来改成这样:

<dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    <version>2.1.3.RELEASE</version>
</dependency>

然后就出现了bus-refresh接口:

温馨提示:答案为网友推荐,仅供参考
相似回答
大家正在搜