ALF-9613: caching content store. Various improvements and bug fixes. Including:

ALF-10097: disk-persistent cache settings in ehcache
ALF-10098: clean up  process should remove empty parent directories from content cache disk directory
ALF-10126: timeToIdle ehcache property was not affecting cache cleaner job
ALF-10127: externally deleted cached content files were not re-cached until after the items expired from ehcache

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@30171 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Matt Ward
2011-09-02 09:03:49 +00:00
parent 1b2e8c53ec
commit ac8b3ce1fc
11 changed files with 409 additions and 71 deletions

View File

@@ -107,6 +107,12 @@ public class ContentCacheImpl implements ContentCache
if (memoryStore.contains(url))
{
String path = memoryStore.get(url);
// Getting the path for a URL from the memoryStore will reset the timeToIdle for
// that URL. It is important to perform a reverse lookup as well to ensure that the
// cache file path to URL mapping is also kept in the cache.
memoryStore.get(Key.forCacheFile(path));
File cacheFile = new File(path);
if (cacheFile.exists())
{