reddycharan commented on a change in pull request #1319:  Issue 1316: A bookie 
with non-writable dirs should be able to start in readonly mode
URL: https://github.com/apache/bookkeeper/pull/1319#discussion_r179677896
 
 

 ##########
 File path: 
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/EntryLogger.java
 ##########
 @@ -416,8 +423,10 @@ File getCurCompactionLogFile() {
     protected void initialize() throws IOException {
         // Register listener for disk full notifications.
         ledgerDirsManager.addLedgerDirsListener(getLedgerDirsListener());
-        // create a new log to write
-        createNewLog();
+
+        if (ledgerDirsManager.hasWritableLedgerDirs()) {
+            createNewLog();
 
 Review comment:
   Hey @sijie with my change EntryLogManager/EntryLogPerLedger I'm removing 
initialize method all together. active entrylog (currentlogchannel) would be 
created on the first addEntry request. So this change wont be required once my 
change gets in. https://github.com/apache/bookkeeper/pull/1281

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to