rishabhdaim commented on code in PR #1075:
URL: https://github.com/apache/jackrabbit-oak/pull/1075#discussion_r1298074309
##########
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/VersionGarbageCollector.java:
##########
@@ -685,6 +686,9 @@ private void collectDetailedGarbage(final GCPhases phases,
final RevisionVector
modified, fromModifiedMs,
toModifiedMs);
}
}
+ if (infoFullGCEnabled) {
+ return;
Review Comment:
Rather than adding the `if-else` check here, I would ignore the deletion
part inside `removeGarbage()`.
It would keep the flow simple and inside the `dryRun` mode, we can `log` the
`properties/documents` that would have been deleted.
The same should be followed for other deletion operations for `deletingDocs`
& `splitCleanUp`.
Following this approach wouldn't skip the iterating logic and thus avoid any
unintended consequences.
cc @stefan-egli @mreutegg
##########
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/VersionGarbageCollector.java:
##########
@@ -122,6 +122,7 @@ public class VersionGarbageCollector {
*/
static final String SETTINGS_COLLECTION_DETAILED_GC_DOCUMENT_ID_PROP =
"detailedGCId";
+ public boolean infoFullGCEnabled = false;
Review Comment:
I would change this name to `dryRun` to indicate the intent of this flag.
##########
oak-run/src/main/java/org/apache/jackrabbit/oak/run/RevisionsCommand.java:
##########
@@ -93,6 +94,7 @@ private static class RevisionsOptions extends
Utils.NodeStoreOptions {
static final String CMD_COLLECT = "collect";
static final String CMD_RESET = "reset";
static final String CMD_SWEEP = "sweep";
+ static final String CMD_INFOFULLGC = "infofullgc";
Review Comment:
I would rename this to `dryRunDetailedGC`
--
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]