最近在研究SpringCloud,这应该是最新版本了吧,网上资料较少,记一下在使用SpringCloud Config自动更新配置spring-cloud-starter-bus-amqp时遇到的一个问题,与诸君共勉。
2021.0.0 2.6.2
自动配置时调用/actuator/bus-refresh接口,用POST方式时产生以下错误:
{ "timestamp": "2022-01-01T14:42:41.767+00:00", "status": 405, "error": "Method Not Allowed", "path": "/actuator/bus-refresh" }
后台服务报这个错误
Resolved [org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported]
这是因为版本更新的缘故,新版本应该使用/actuator/busrefresh,就不存在问题了。在网上找了好久没发现正解,希望能帮到大家。
哎。。。版本问题真是坑人,整了我一个晚上。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)