首页
系统
动态
电子资讯
硬件
数码
软件介绍
网络软件
系统工具
应用软件
图形图像
多媒体
编程开发
字体下载
登录
标签
userServiceImpl
Bean named ‘userServiceImpl‘ is expected to be of type ‘com.woniu.service.UserServiceImpl‘ but was a
错误代码: RestControllerRequestMapping("user")public class UserServlet {Autowiredprivate UserServic
userServiceImpl
expected
bean
named
Service
admin
11天前
6
0
Bean named ‘userServiceImpl‘ is expected to be of type ‘xxxxx‘ but was actually of type ‘xxxxxx‘
在写测试时发现这个报错原因是在注入依赖时写的是实现类,而不是接口 解决:将注入实现类改为注入接口然后就查询成功了总结: 如果你的代码中使用了 AOP 或者
userServiceImpl
named
bean
expected
xxxxxx
admin
11天前
4
0