我在学习spring cloud的过程中,遇到了一些问题;
1.spring cloud 中的application.yml和bootstrap.yml有什么区别,我在git端同时配置了application和bootstrap两个文件,为什么在客户端调用时,默认只能访问到application中的参数,bootstrap中的访问不到;
2.client连接server之后,修改了git端的配置文件,这个时候用curl -X POST localhost:8080/refresh 刷新为什么没有反应,报错:
curl -X POST http://localhost:8080/refresh
{"timestamp":1456470896361,"status":405,"error":"Method Not Allowed","exception":"org.springframework.web.HttpRequestMethodNotSupportedException","message":"Request method 'POST' not supported","path":"/refresh"}
我也遇到了这个问题,还没有解决回复<aclass='referer'target='_blank'>@醉生梦死丶:这两种方式的curl用法都是发起post请求,405的原因在于忘了引入一个包造成的。curl-d""http://localhost:8080/refresh
集结各类场景实战经验,助你开发运维畅行无忧