public static void recoverFileLease(FileSystem fs, Path p, Configuration conf,
    CancelableProgressable reporter) throws IOException {
    if (fs instanceof FilterFileSystem) {
      fs = ((FilterFileSystem) fs).getRawFileSystem();
    }

    // lease recovery not needed for local file system case.
    if (isLeaseRecoverable(fs)) {
      recoverDFSFileLease(fs, p, conf, reporter);
    }
  }
Recover the lease from Hadoop file system, retrying multiple times.
hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/util/RecoverLeaseFSUtils.java