private void put(Buffer buffer) throws IOException { while (true) { checkForWriterException(); try { if (writeQueue.offer(buffer, 1, TimeUnit.SECONDS)) break; } catch (InterruptedException e) { throw new RuntimeException(e); } } }
private void put(Buffer buffer) throws IOException { while (true) { checkForWriterException(); try { if (writeQueue.offer(buffer, 1, TimeUnit.SECONDS)) break; } catch (InterruptedException e) { throw new RuntimeException(e); } } }
private void put(Buffer buffer) throws IOException { while (true) { checkForWriterException(); try { if (writeQueue.offer(buffer, 1, TimeUnit.SECONDS)) break; } catch (InterruptedException e) { throw new RuntimeException(e); } } }
private void put(Buffer buffer) throws IOException { while (true) { checkForWriterException(); try { if (writeQueue.offer(buffer, 1, TimeUnit.SECONDS)) break; } catch (InterruptedException e) { throw new RuntimeException(e); } } }
@Override public void close() throws IOException { sync(); put(SENTINEL); try { diskWriter.join(); checkForWriterException(); } catch (Throwable e) { throw new RuntimeException(e); } checkForWriterException(); }
@Override public void close() throws IOException { sync(); put(SENTINEL); try { diskWriter.join(); checkForWriterException(); } catch (Throwable e) { throw new RuntimeException(e); } checkForWriterException(); }
@Override public void close() throws IOException { sync(); put(SENTINEL); try { diskWriter.join(); checkForWriterException(); } catch (Throwable e) { throw new RuntimeException(e); } checkForWriterException(); }