Springboot Whitelabel Error Page

后端 未结 1 1295
旧时难觅i
旧时难觅i 2021-01-14 03:20

I stuck with this simple MVC example. When I start the App and go to localhost:8080, I got \"Whitelabel Error Page\", even I created \"index.html\" in \"src/main/resources/t

相关标签:
1条回答
  • 2021-01-14 03:22

    As you can see in the log your controller wasn't found and registered by Spring. Probably, because it belongs to the package that wasn't auto scanned for the classes. To fix so, I suggest to update the structure of the code to the structure that is advised in the documentation. Another way to fix it is to try to specify @ComponentScan manually.

    0 讨论(0)
提交回复
热议问题