title: Make EHCache expire elements which have not been accessed in a specific way
body: <p>I'm trying to get EHCache to mark cache elements as expired if they have not been accessed in a particular way, within a specified amount of time.</p>
  
  <p>I have an automated cache-refresher which should refresh elements in the cache without updating the last-accessed time. It runs on a regular schedule. However, if a user requests something from the cache through the application, then the last-accessed time should be updated. Elements should expire and be removed from the cache after a week of user inactivity.</p>
  
  <p>Does EHCache have anything already in-place that would solve this sort of problem? I see the <a href="http://ehcache.org/apidocs/net/sf/ehcache/Cache.html#putQuiet%28net.sf.ehcache.Element%29" rel="nofollow">putQuiet</a> and <a href="http://ehcache.org/apidocs/net/sf/ehcache/Cache.html#getQuiet%28java.io.Serializable%29" rel="nofollow">getQuiet</a> methods, but I don't see any explicit mention of them not updating the last-accessed time. Also, is there any real difference between the <a href="http://ehcache.org/apidocs/net/sf/ehcache/config/CacheConfiguration.html#timeToLiveSeconds" rel="nofollow">timeToLiveSeconds</a> and <a href="http://ehcache.org/apidocs/net/sf/ehcache/config/CacheConfiguration.html#timeToIdleSeconds" rel="nofollow">timeToIdleSeconds</a> parameters?</p>
  
  <p>Thanks,
  Mike</p>