错误描述:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is org.hibernate.InvalidMappingException: Could not parse mapping document from invalid mapping
Caused by: org.hibernate.InvalidMappingException: Could not parse mapping document from invalid mapping
at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:508)
at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:651)
解决方法:
把Reference librarie下的asm-2-2-3.jar包删除掉,再试试!
本文介绍了一种常见的Spring与Hibernate集成时出现的问题:在启动应用过程中SessionFactory bean创建失败,抛出InvalidMappingException异常。文章提供了具体的错误堆栈信息,并给出了有效的解决方案——移除导致问题的asm-2.2.3.jar依赖文件。
2万+

被折叠的 条评论
为什么被折叠?



