karanmehta93 opened a new issue #2178: JournalChannel should throw IOException if it cannot seek to desired position URL: https://github.com/apache/bookkeeper/issues/2178 **BUG REPORT** ***Describe the bug*** Here's a piece of code from `JournalChannel.java` ``` try { if (position == START_OF_FILE) { if (formatVersion >= V5) { fc.position(HEADER_SIZE); } else if (formatVersion >= V2) { fc.position(VERSION_HEADER_SIZE); } else { fc.position(0); } } else { fc.position(position); } } catch (IOException e) { LOG.error("Bookie journal file can seek to position :", e); <-- Swallows IOException and moves on } ``` ***To Reproduce*** Create a corrupt journal file. Try seeking to the desired position. ***Expected behavior*** IOException should be thrown and bookie should be shutdown. Not sure if a retry would help. It's not really recoverable since journal file is corrupted. @reddycharan @jvrao @eolivelli Another potential problem?
---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
