jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chet...@apache.org
Subject svn commit: r1550149 - /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java
Date Wed, 11 Dec 2013 14:25:51 GMT
Author: chetanm
Date: Wed Dec 11 14:25:51 2013
New Revision: 1550149

URL: http://svn.apache.org/r1550149
Log:
OAK-1276 MongoDocumentStore sometimes returns NodeDocument.NULL instead of null document

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java?rev=1550149&r1=1550148&r2=1550149&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoDocumentStore.java
Wed Dec 11 14:25:51 2013
@@ -167,6 +167,9 @@ public class MongoDocumentStore implemen
             if (doc != null) {
                 if (maxCacheAge == Integer.MAX_VALUE ||
                         System.currentTimeMillis() - doc.getCreated() < maxCacheAge) {
+                    if (doc == NodeDocument.NULL) {
+                        return null;
+                    }
                     return (T) doc;
                 }
             }



Mime
View raw message