You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bookkeeper.apache.org by gi...@git.apache.org on 2017/07/24 21:53:22 UTC

[GitHub] sijie opened a new issue #280: Turn bookie into readonly when SortedLedgerStorage fails to flush data

sijie opened a new issue #280: Turn bookie into readonly when SortedLedgerStorage fails to flush data
URL: https://github.com/apache/bookkeeper/issues/280
 
 
   
   **FEATURE REQUEST**
   
   1. Please describe the feature you are requesting.
   
   Address the TODO item in `SortedLedgerStorage`
   
   scheduler.execute(new Runnable() {
               @Override
               public void run() {
                   try {
                       LOG.info("Started flushing mem table.");
                       long logIdBeforeFlush = entryLogger.getCurrentLogId();
                       memTable.flush(SortedLedgerStorage.this);
                       long logIdAfterFlush = entryLogger.getCurrentLogId();
                       // in any case that an entry log reaches the limit, we roll the log and start checkpointing.
                       // if a memory table is flushed spanning over two entry log files, we also roll log. this is
                       // for performance consideration: since we don't wanna checkpoint a new log file that ledger
                       // storage is writing to.
                       if (entryLogger.reachEntryLogLimit(0) || logIdAfterFlush != logIdBeforeFlush) {
                           entryLogger.rollLog();
                           LOG.info("Rolling entry logger since it reached size limitation");
                       }
                   } catch (IOException e) {
                       // TODO: if we failed to flush data, we should switch the bookie back to readonly mode
                       //       or shutdown it.
                       LOG.error("Exception thrown while flushing skip list cache.", e);
                   }
               }
           });
   
   2. Indicate the importance of this issue to you (blocker, must-have, should-have, nice-to-have). Are you currently using any workarounds to address this issue?
   
   *nice-to-have*
   
   3. Provide any additional detail on your proposed use case for this feature.
   
   N/A
   
   
 
----------------------------------------------------------------
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