Author: mreutegg Date: Tue Apr 29 14:17:03 2014 New Revision: 1590988 URL: http://svn.apache.org/r1590988 Log: OAK-1779: Stale cache after MongoMK GC
Invalidate the docChildrenCache when we detect it is stale Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStore.java Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStore.java URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStore.java?rev=1590988&r1=1590987&r2=1590988&view=diff ============================================================================== --- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStore.java (original) +++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStore.java Tue Apr 29 14:17:03 2014 @@ -817,6 +817,7 @@ public final class DocumentNodeStore String p = PathUtils.concat(path, name); NodeDocument doc = store.find(Collection.NODES, Utils.getIdFromPath(p)); if (doc == null) { + docChildrenCache.invalidateAll(); throw new NullPointerException("Document " + p + " not found"); } return doc;