nit0906 commented on a change in pull request #370:
URL: https://github.com/apache/jackrabbit-oak/pull/370#discussion_r707242290



##########
File path: 
oak-lucene/src/main/java/org/apache/jackrabbit/oak/plugins/index/lucene/LuceneIndexInfoProvider.java
##########
@@ -140,6 +139,24 @@ private static void computeLastUpdatedTime(NodeState 
idxState, LuceneIndexInfo i
         }
     }
 
+    private static void checkIfHiddenNodesExists(NodeState idxState, 
LuceneIndexInfo info) {
+        // Check for hidden oak libs mount node that has indexed content for 
read only repo in composite store
+        info.hasHiddenOakLibsMount = false;
+        for(String c : idxState.getChildNodeNames()) {
+            if (c.startsWith(IndexDefinition.HIDDEN_OAK_MOUNT_PREFIX)) {
+                info.hasHiddenOakLibsMount = true;
+            }
+        }
+
+        // Now check for hidden property index node :property-index - present 
in case of hybrid indexes
+        info.hasPropertyIndexNode = false;
+        for(String c : idxState.getChildNodeNames()) {
+            if (c.equals(IndexDefinition.PROPERTY_INDEX)) {
+                info.hasPropertyIndexNode = true;
+            }
+        }
+    }

Review comment:
       @fabriziofortino  - I modified it to be in one for loop. I didn't add 
the break statement, because the we only have fixed 3-4 child nodes here. So 
break statement is not required as such.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to