spring升级到4.x后,orm包里面移除了对ibatis的支持,这是为什么
关注
码龄 粉丝数 原力等级 --
- 被采纳
- 被点赞
- 采纳率

已采纳
spring升级到4.x后,orm包里面移除了对ibatis的支持,这是为什么
收起
- 写回答
- 好问题 0 提建议
- 关注问题
微信扫一扫
点击复制链接分享
- 邀请回答
- 编辑 收藏 删除 结题
- 收藏 举报
2条回答 默认 最新
- 关注
码龄 粉丝数 原力等级 --
- 被采纳
- 被点赞
- 采纳率
关注
Basically you just have to add this dependency to your project:
<dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis-2-spring</artifactId> <version>1.0.1</version> </dependency>
Here are detail explanations.
Spring 4 got you down with no ibatis support - no worries Mybatis has your back Spring is well on it's way to leaving 3 behind. For ibatis users that for one reason or another are stuck to ibatis, but want to just make the jump to spring 4, there is a dilemma. This dilemma roots in the fact that spring team dropped ibatis in spring 4. Until now this meant that upgrading to spring 4 required upgrading ibatis to mybatis and mybatis-spring. Well in order to mitigate risk to those that need it, mybatis team has decided to extract the spring 3 ibatis support into a new mybatis project called 'mybatis-2-spring'. Better still, we go one step further and have released a fresh copy of 'mybatis-2'. So there you have it, all of the users out there dealing with legacy code, mybatis is no longer directly tied into the mix resulting in higher risk in upgrading. With that said, enjoy what's left in the ibatis land as we resurrect the past.
refer url:http://stackoverflow.com/questions/32353286/no-support-for-ibatis-in-spring4-2-0
本回答被题主选为最佳回答 , 对您是否有帮助呢? 本回答被专家选为最佳回答 , 对您是否有帮助呢? 本回答被题主和专家选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏举报微信扫一扫
点击复制链接分享
编辑预览轻敲空格完成输入- 显示为
- 卡片
- 标题
- 链接
评论按下Enter换行,Ctrl+Enter发表内容
编辑
预览

轻敲空格完成输入
- 显示为
- 卡片
- 标题
- 链接
报告相同问题?
提交
- 2022-08-23 08:25
Exception in thread "main" org.springframework.dao.InvalidDataAccessApiUsageException java spring 有问必答
回答 4 已采纳 把persistence.xml放在src下的META-INF文件中 Spring jpa异常_jan2022的博客-CSDN博客 Exc - 2022-05-16 07:27回答 1 已采纳 将 <dependency> <groupId>org.apache.shiro</groupId>
- 2022-03-08 15:56
Springboot 出现java.lang.IllegalStateException: Failed to load ApplicationContext intellij-idea java spring boot 有问必答
回答 4 已采纳 确保你的测试类与启动类是在同一个包下,这样你的springbootTest注解可以不用加启动类路径,否则需要加上,另外你也可以试着先在这个注解上面加上这个注解@RunWith(SpringRunner - 2017-02-11 17:39weixin_34288121的博客 2019独角兽企业重金招聘Python工程师标准>>> ...
- 2022-06-07 10:14回答 2 已采纳 把数据库字段改了,这种不规范字段留着也是个祸害。你现在不改,以后还得出问题。市面上大部分工具都不会支持你这个带点的字段,长痛不如短痛。这个可以关转换,你试试,但真的不推荐 jpa: hibern
- 2021-12-15 08:33回答 5 已采纳 配置的问题,仔细检查你的配置文件,例如yaml文件,看看是否少写或多写了空格。
- 2022-08-11 08:35回答 1 已采纳 java.lang.ClassCastException: org.springframework.orm.jpa.EntityManagerHolder cannot be cast to org.
- 2022-01-20 03:28对方正在输入中.. ......的博客 记录ibatis+spring升级到ibatis+spring boot遇到的问题 注:没有将ibatis替换成为mybaits,xml配置也没有干掉,因为这样改动最小
- 2019-11-18 13:36
java.lang.IllegalStateException: Failed to load ApplicationContext eclipse hibernate java spring struts
回答 1 已采纳 hibernate-jpa-2.0-api-1.0.1.Final.jar这个包也检查有?tomcat版本?可以升级下版本看看 - 2021-12-13 07:38回答 2 已采纳 SimpleDateFormat 不是线程安全类,这个不要定义为静态的,如有帮助请采纳
- 2021-05-29 13:09回答 2 已采纳 可以试试mysql的Concat函数
- 2024-07-02 06:53百里晓生的博客 检页面是否存在escape属性将其替换成escapeHtml。不然会报找不到某个方法。
- 2015-04-20 17:28同音乐私奔的博客 因为spring升级到4.x后,orm包里面移除了对ibatis的支持, 如果orm使用4.x版本的话项目会启动失败。 查看orm-3.x版本的SqlMapClientFactoryBean类,里面说的很清楚,只支持到3.x。 如果可以升级到mybatis的话尽量...
- 2020-02-24 12:50最初的节奏的博客 spring版本升级到4.2.5 点关注不迷路,欢迎再访! 目录spring版本升级到4.2.5一、新特性介绍二.引入依赖三.踩雷指南 一、新特性介绍 Spring 4 相比 Spring 3,引入许多新特性,这里列举几条较为重要的: 1.支持 ...
- 2017-08-03 07:24IDEA SpringMVC集成mybatis教程。 配套教程http://blog.csdn.net/ljheee/article/details/76618762 2个实体类的orm,增删改查实现。
- 没有解决我的问题, 去提问
联系我们(工作时间:8:30-22:00)
400-660-0108kefu@csdn.net在线客服
- 京ICP备19004658号
- 经营性网站备案信息
公安备案号11010502030143
- 营业执照
- 北京互联网违法和不良信息举报中心
- 家长监护
- 中国互联网举报中心
- 网络110报警服务
- Chrome商店下载
- 账号管理规范
- 版权与免责声明
- 版权申诉
- 出版物许可证
- ©1999-2025北京创新乐知网络技术有限公司