Error was tenMinuteCache Cache: The Disk store is not active.

ehcache could not remove disk store for sql

2010-4-13 9:42:13 org.apache.catalina.core.StandardWrapperValve invoke
严重: Servlet.service() for servlet jsp threw exception
net.sf.ehcache.CacheException: tenMinuteCacheCache: Could not remove disk store entry for class com.chinaclick.terry.util.ContentUtils_20. Error was tenMinuteCache Cache: The Disk store is not active.
at net.sf.ehcache.store.DiskStore.remove(DiskStore.java:469)
at net.sf.ehcache.Cache.remove(Cache.java:1101)
at net.sf.ehcache.Cache.searchInMemoryStore(Cache.java:908)
at net.sf.ehcache.Cache.get(Cache.java:733)
at net.sf.ehcache.Cache.get(Cache.java:710)
at com.chinaclick.allen.front.util.ShowUtil.getObject(ShowUtil.java:223)
at com.chinaclick.terry.util.ContentUtils.getNews(ContentUtils.java:204)
at org.apache.jsp.front.index_jsp._jspService(index_jsp.java:142)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at sun.reflect.GeneratedMethodAccessor43.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)

 

是缓存路径问题

 

首先说明:我们在ehcache.xml  <diskStore path="java.io.tmpdir"/>配置了缓存溢出到的磁盘路径

可以通过:

Java代码 复制代码  收藏代码
  1. System.out.println(System.getProperty("java.io.tmpdir"));  
  1. 在文件按目录下有一下文件:   
  2. com.eric.po.B.data--------0kb   
  3. cache_a.data   ------------4 kb   
  4. org.hibernate.cache.StandardQueryCache.data  ---0kb   
  5. org.hibernate.cache.UpdateTimestampsCache.data -----0kb  
在文件按目录下有一下文件:
com.eric.po.B.data--------0kb
cache_a.data   ------------4 kb
org.hibernate.cache.StandardQueryCache.data  ---0kb
org.hibernate.cache.UpdateTimestampsCache.data -----0kb

 
其中   cache_a中保存了我们的缓存文件

StandardQueryCache.data 则是 设置默认的查询缓存的数据过期策略  产生的文件,

org.hibernate.cache.UpdateTimestampsCache.data则是 设置时间戳缓存的数据过期策略 

如果不适用我们自己的缓存配置就会使用类类的全路径路径文件(com.eric.po.B.data)来缓存我们的数据。

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值