stefan-egli commented on code in PR #1779:
URL: https://github.com/apache/jackrabbit-oak/pull/1779#discussion_r1829241458
##########
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStoreBuilder.java:
##########
@@ -915,7 +922,25 @@ public NodeDocumentCache
buildNodeDocumentCache(DocumentStore docStore, NodeDocu
return new NodeDocumentCache(nodeDocumentsCache,
nodeDocumentsCacheStats, prevDocumentsCache, prevDocumentsCacheStats, locks);
}
- public Cache<StringValue, StringValue>
buildPrevNoPropCache(DocumentNodeStore store) {
+ /**
+ * Checks the feature toggle for prevNoProp cache and returns true if
that's enabled
+ * @return true if the prevNoProp feature toggle is enabled, false
otherwise
+ */
+ private boolean isPrevNoPropCacheEnabled() {
+ final Feature prevNoPropFeature = getPrevNoPropCacheFeature();
+ return prevNoPropFeature != null && prevNoPropFeature.isEnabled();
+ }
+
+ /**
+ * Builds the prevNoProp cache, if the corresponding feature toggle is
enabled.
+ * Returns null otherwise
+ * @return null if prevNoProp feature is disabled and size non-null, a
newly built cache otherwise
+ */
+ public Cache<StringValue, StringValue> buildPrevNoPropCacheOrNull() {
Review Comment:
true, done in
https://github.com/apache/jackrabbit-oak/pull/1779/commits/d1e238578ae11092a46d078b34e0d0443364c381
--
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]