You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bookkeeper.apache.org by GitBox <gi...@apache.org> on 2019/02/18 22:22:20 UTC

[GitHub] rdhabalia commented on a change in pull request #1949: [bookie-gc] add option for persistent entry-log metadata map

rdhabalia commented on a change in pull request #1949: [bookie-gc] add option for persistent entry-log metadata map
URL: https://github.com/apache/bookkeeper/pull/1949#discussion_r257838744
 
 

 ##########
 File path: bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/GarbageCollectorThread.java
 ##########
 @@ -127,35 +127,41 @@ public GarbageCollectorThread(ServerConfiguration conf, LedgerManager ledgerMana
                 Executors.newSingleThreadScheduledExecutor(new DefaultThreadFactory("GarbageCollectorThread")));
     }
 
+    private EntryLogMetadataMap createEntryLogMetadataMap(boolean gcPersistentEntrylogMetadataMapEnabled) {
+        final String baseDir = this.entryLogger.getLedgerDirsManager().getAllLedgerDirs().get(0).toString();
 
 Review comment:
   > what happens if you have more than one "ledgerDir" ? should this directory be configurable ?
   
   actually, that doesn't matter because here we use it to just get the base dir path of ledger so, we can create dedicated dir to store metadata and that is independent of multi-ledger dir usecase. also we do similar at [multiple places](https://github.com/apache/bookkeeper/blob/master/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/BookieShell.java#L2869) to get base-dir path for the entry-logger and stores rocksDB dir under it.
   However, we can also add config to get dir path and fallback to this logic if config is not provided. I will add it.

----------------------------------------------------------------
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