bookkeeper-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] sijie commented on a change in pull request #1838: Add rest endpoint trigger_gc to trigger GC on Bookie
Date Mon, 26 Nov 2018 18:35:29 GMT
sijie commented on a change in pull request #1838: Add rest endpoint trigger_gc to trigger
GC on Bookie
URL: https://github.com/apache/bookkeeper/pull/1838#discussion_r236373826
 
 

 ##########
 File path: bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java
 ##########
 @@ -382,6 +382,13 @@ public void runWithFlags(boolean force, boolean suspendMajor, boolean
suspendMin
             lastMinorCompactionTime = System.currentTimeMillis();
             minorCompactionCounter.inc();
         }
+
+        if (force) {
+            if (forceGarbageCollection.compareAndSet(true, false)) {
+                LOG.info("{} Set forceGarbageCollection to true after force GC to make it
forceGC-able again.", Thread
 
 Review comment:
   Also doesn't https://github.com/apache/bookkeeper/blob/master/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java#L338
already do that?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message