在创建Springboot工程时,有时也会遇到no such bean问题,如图所示
此时应该检查此类所在的包正不正确,一定要放在启动类所在包或者子包中。
其次检查此类有没有使用spring指定的注解进行描述(例如@Component)
Could not autowire. No beans of ‘DefaultCache‘ type found报错的原因
猜你喜欢
转载自blog.csdn.net/weixin_45015214/article/details/111830217
今日推荐
周排行