@Override public void recoverFileLease(final FileSystem fs, final Path path) throws IOException { final Configuration conf = master.getConfiguration(); final FSUtils fsUtils = FSUtils.getInstance(fs, conf); fsUtils.recoverFileLease(fs, path, conf, new CancelableProgressable() { @Override public boolean progress() { LOG.debug("Recover Procedure Store log lease: " + path); return isRunning(); } }); }
private static void recoverLease(final Configuration conf, final Path path) { try { final FileSystem dfs = FSUtils.getCurrentFileSystem(conf); FSUtils fsUtils = FSUtils.getInstance(dfs, conf); fsUtils.recoverFileLease(dfs, path, conf, new CancelableProgressable() { @Override public boolean progress() { LOG.debug("Still trying to recover WAL lease: " + path); return true; } }); } catch (IOException e) { LOG.warn("unable to recover lease for WAL: " + path, e); } }
private void recoverLease(final Configuration conf, final Path path) { try { final FileSystem dfs = CommonFSUtils.getWALFileSystem(conf); FSUtils fsUtils = FSUtils.getInstance(dfs, conf); fsUtils.recoverFileLease(dfs, path, conf, new CancelableProgressable() { @Override public boolean progress() { LOG.debug("recover WAL lease: " + path); return true; } }); } catch (IOException e) { LOG.warn("unable to recover lease for WAL: " + path, e); } }
private Reader getReader(String wal) throws IOException { Path path = new Path(rs.getWALRootDir(), wal); long length = rs.getWALFileSystem().getFileStatus(path).getLen(); try { FSUtils.getInstance(fs, conf).recoverFileLease(fs, path, conf); return WALFactory.createReader(rs.getWALFileSystem(), path, rs.getConfiguration()); } catch (EOFException e) { if (length <= 0) { LOG.warn("File is empty. Could not open {} for reading because {}", path, e); return null; } throw e; } }
FSUtils.getInstance(walFS, conf).recoverFileLease(walFS, path, conf, reporter); try { in = getReader(path, reporter);
} else { LOG.debug("_balancedSplit file found. Replay log to restore state..."); FSUtils.getInstance(fs, connection.getConfiguration()) .recoverFileLease(fs, splitFile, connection.getConfiguration(), null);
EventLoopGroup eventLoopGroup, Class<? extends Channel> channelClass) throws IOException { Configuration conf = dfs.getConf(); FSUtils fsUtils = FSUtils.getInstance(dfs, conf); DFSClient client = dfs.getClient(); String clientName = client.getClientName();
FSUtils fsUtils = FSUtils.getInstance(fs, TEST_UTIL.getConfiguration()); for (Path p : paths) { LOG.debug("recovering lease for " + p);
@Override public void recoverFileLease(final FileSystem fs, final Path path) throws IOException { final Configuration conf = master.getConfiguration(); final FSUtils fsUtils = FSUtils.getInstance(fs, conf); fsUtils.recoverFileLease(fs, path, conf, new CancelableProgressable() { @Override public boolean progress() { LOG.debug("Recover Procedure Store log lease: " + path); return master.isActiveMaster(); } }); } }
private void recoverLease(final Configuration conf, final Path path) { try { final FileSystem dfs = FSUtils.getCurrentFileSystem(conf); FSUtils fsUtils = FSUtils.getInstance(dfs, conf); fsUtils.recoverFileLease(dfs, path, conf, new CancelableProgressable() { @Override public boolean progress() { LOG.debug("recover WAL lease: " + path); return isWorkerActive(); } }); } catch (IOException e) { LOG.warn("unable to recover lease for WAL: " + path, e); } }
FSUtils.getInstance(fs, conf).recoverFileLease(fs, path, conf); try { in = getReader(fs, path, conf);
} else { LOG.debug("_balancedSplit file found. Replay log to restore state..."); FSUtils.getInstance(fs, table.getConfiguration()) .recoverFileLease(fs, splitFile, table.getConfiguration());
FSUtils.getInstance(fs, conf).recoverFileLease(fs, path, conf, reporter); try { in = getReader(path, reporter);
} else { LOG.debug("_balancedSplit file found. Replay log to restore state..."); FSUtils.getInstance(fs, connection.getConfiguration()) .recoverFileLease(fs, splitFile, connection.getConfiguration(), null);
FSUtils fsUtils = FSUtils.getInstance(fs, TEST_UTIL.getConfiguration()); for (Path p : paths) { LOG.debug("recovering lease for " + p);