This application has no explicit mapping for /error, so you are seeing this as a fallback.

{
"timestamp": 1579256897101,
"status": 404,
"error": "Not Found",
"message": "No message available",
"path": "/tmallgenie/getResponse"
}

Application启动类的位置不对:要将Application类放在最外侧,即包含所有子包 ,spring-boot会自动加载启动类所在包下及其子包下的所有组件。

或者

@ComponentScan({"xx.xxx.xx"})

参考https://blog.csdn.net/qushaming/article/details/94593675

原文地址:https://www.cnblogs.com/angelica-duhurica/p/12207140.html