如上提醒表示当前不是Spring管理着呢,是你的数据库插件Mybatis或者MybatisPlus给你管理呢,所以Spring给你温馨提醒了一下而已,又没有报错!
解决的办法是在数据查找的方法上添加
@Transactional
然后就会变成spring管理啦,同时会变成事务的形式,方法中的任何报错都会导致方法回滚!

版权归原作者 小林嘞 所有, 如有侵权,请联系我们删除。
如上提醒表示当前不是Spring管理着呢,是你的数据库插件Mybatis或者MybatisPlus给你管理呢,所以Spring给你温馨提醒了一下而已,又没有报错!
解决的办法是在数据查找的方法上添加
@Transactional
然后就会变成spring管理啦,同时会变成事务的形式,方法中的任何报错都会导致方法回滚!

@Autowired报错Could not autowire. No beans of ‘XXX‘ type found
Could not resolve placeholder “xxx“ in value “${}“
maven父工程出现Could not find artifact xxx异常
[报错解决](Error Creating bean with name ‘xxx‘)类问题解决思路
MacOS 终端中创建文件遇见mkdir: /xxx: Read-only file system问题解决方案
Cannot determine value type from string ‘xxx‘
feign.FeignException: status 400 reading xxx 异常解决方案
SpringCloud微服务项目实战(一)---搭建SpringBoot项目
SpringCloud Gateway网关多路由配置访问404解决方案
Java 对象拷贝与转换-org.mapstruct:mapstruct 包(@Mapper、@Mapping)的使用