ehcache版本问题导致的一个错误edu.emory.mathcs.backport...

  1. org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in file [C:\eclipse3.6\workspace\ssms\WebContent\WEB-INF\applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue  
  2. Caused by: java.lang.NoClassDefFoundError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue  
  3.     at net.sf.ehcache.config.ConfigurationHelper.createCache(ConfigurationHelper.java:418)  
  4.     at net.sf.ehcache.config.ConfigurationHelper.createDefaultCache(ConfigurationHelper.java:334)  
  5.     at net.sf.ehcache.CacheManager.configure(CacheManager.java:306)  
  6.     at net.sf.ehcache.CacheManager.init(CacheManager.java:226)  
  7.     at net.sf.ehcache.CacheManager.<init>(CacheManager.java:213)  
  8.     at net.sf.ehcache.CacheManager.create(CacheManager.java:394)  
  9.     at org.hibernate.cache.EhCacheProvider.start(EhCacheProvider.java:124)  
  10.     at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:169)  
  11.     at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1005)  
  12.     at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:805)  
  13.     at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:745)  
  14.     at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:134)  
  15.     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)  
  16.     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)  
  17.     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)  
  18.     at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)  
  19.     at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)  
  20.     at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)  
  21.     at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)  
  22.     at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:284)  
  23.     at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)  
  24.     at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:93)  
  25.     at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:77)  
  26.     at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:67)  
  27.     at com.ssms.hibernate.test.UserDAOTest.setUp(UserDAOTest.java:20)  
  28.     at junit.framework.TestCase.runBare(TestCase.java:132)  
  29.     at junit.framework.TestResult$1.protect(TestResult.java:110)  
  30.     at junit.framework.TestResult.runProtected(TestResult.java:128)  
  31.     at junit.framework.TestResult.run(TestResult.java:113)  
  32.     at junit.framework.TestCase.run(TestCase.java:124)  
  33.     at junit.framework.TestSuite.runTest(TestSuite.java:243)  
  34.     at junit.framework.TestSuite.run(TestSuite.java:238)  
  35.     at junit.framework.TestSuite.runTest(TestSuite.java:243)  
  36.     at junit.framework.TestSuite.run(TestSuite.java:238)  
  37.     at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)  
  38.     at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)  
  39.     at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)  
  40.     at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)  
  41.     at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)  
  42.     at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)  
  43.     at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)  
  44. Caused by: java.lang.ClassNotFoundException: edu.emory.mathcs.backport.java.util.concurrent.BlockingQueue  
  45.     at java.net.URLClassLoader$1.run(URLClassLoader.java:200)  
  46.     at java.security.AccessController.doPrivileged(Native Method)  
  47.     at java.net.URLClassLoader.findClass(URLClassLoader.java:188)  
  48.     at java.lang.ClassLoader.loadClass(ClassLoader.java:306)  
  49.     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)  
  50.     at java.lang.ClassLoader.loadClass(ClassLoader.java:251)  
  51.     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)  
  52.     ... 41 more  

 

 

使用ehcache-1.5.0.jar出现如上错误;使用ehcache-1.3.jar问题解决。

出自:http://zuoqiang.iteye.com/blog/755756

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值