首页 > 编程语言 > 详细

springMvc整合hibernate出现的问题

时间:2015-03-13 16:47:09      阅读:465      评论:0      收藏:0      [点我收藏+]
Caused by: java.lang.NoSuchFieldError: TRACE
        at org.jboss.logging.Log4jLogger.translate(Log4jLogger.java:64)
        at org.jboss.logging.Log4jLogger.doLog(Log4jLogger.java:44)
        at org.jboss.logging.Logger.trace(Logger.java:128)
        at org.hibernate.internal.CoreMessageLogger_$logger.trace(CoreMessageLogger_$logger.java:417)
        at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:1311)
        at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1737)
        at org.hibernate.ejb.EntityManagerFactoryImpl.<init>(EntityManagerFactoryImpl.java:94)
        at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:905)
        at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:890)
        at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:74)
        at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:268)
        at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:310)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)

解决办法删除用org.slf4j:slf4j-log4j12:1.6.1替换log4j

springMvc整合hibernate出现的问题

原文:http://my.oschina.net/u/2291124/blog/386725

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!