springboot
UESTC-涛涛
这个作者很懒,什么都没留下…
展开
-
springboot使用@ConfigurationProperties报错Could not autowire. No beans of ‘String‘ type found.并且程序运行错误
报错***************************APPLICATION FAILED TO START***************************Description:Parameter 0 of constructor in com.atguigu.boot.buhui.Car required a bean of type 'java.lang.String' that could not be found.解决方案这是因为自动注入需要无参构造,而我生成构造原创 2021-06-13 19:40:07 · 1787 阅读 · 0 评论 -
@RequestMapping(““)括号里面的内容的作用
今天学习springboot时访问controller类时出现了This application has no explicit mapping for /error, so you are seeing this as a fallback。错误,原因是我没有写后缀localhost:8080/hello中的hello这个hello是在@RequestMapping("/hello")的括号里,如果不写的就定位不到这个类,这样的话就会出现错位。...原创 2021-05-29 15:46:42 · 1365 阅读 · 0 评论