前端报错404,后端显示:[ntloop-thread-7] o.a.s.c.rest.locator.OperationLocator : locate path failed, status:Not Found, http method:GET, path:/, microserviceName:gateway
原因:
在resource-->application.yml中:
# This is web root for windows server, change this path according to where you put your source code
gateway:
webroot: /code/servicecomb-samples/bmi/webapp/src/main/resources/static
解决:
webroot路径配置不正确,改为本地放置servicecomb-samples路径。如:E:/test/servicecomb-samples/.... 应该为: /test/servicecomb-samples/....
文章讨论了前端遇到404错误,后端日志显示找不到路径的问题,原因在于`application.yml`中的webroot配置错误,应将路径设置为本地服务comb-samples的实际位置。解决方法是修正webroot配置为正确的文件路径。

7915

被折叠的 条评论
为什么被折叠?



