浏览 4250 次
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
|
|
---|---|
作者 | 正文 |
发表时间:2010-01-21
<bean id="cacheManager" class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean"> <property name="configLocation"> <value>file:server/ehcache.xml</value> </property> </bean> 总是报错: ... Caused by: java.lang.NoClassDefFoundError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue at net.sf.ehcache.config.ConfigurationHelper.createCache(ConfigurationHelper.java:418) at net.sf.ehcache.config.ConfigurationHelper.createDefaultCache(ConfigurationHelper.java:334) at net.sf.ehcache.CacheManager.configure(CacheManager.java:306) at net.sf.ehcache.CacheManager.init(CacheManager.java:226) at net.sf.ehcache.CacheManager.<init>(CacheManager.java:202) at org.springframework.cache.ehcache.EhCacheManagerFactoryBean.afterPropertiesSet(EhCacheManagerFactoryBean.java:113) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1367) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1333) ... 46 more Caused by: java.lang.ClassNotFoundException: edu.emory.mathcs.backport.java.util.concurrent.BlockingQueue at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) ... 54 more 换了几个版本的ehcache.jar后,发现只有1.5的版本不报错! 大家使用的时候要注意了! 声明:ITeye文章版权属于作者,受法律保护。没有作者书面许可不得转载。
推荐链接
|
|
返回顶楼 | |
发表时间:2010-01-21
你少了包..
|
|
返回顶楼 | |
发表时间:2010-01-22
我的是1.6的,也没错
|
|
返回顶楼 | |