private long getFileSize(Path currentPath) throws IOException {
    long fileSize;
    try {
      fileSize = fs.getContentSummary(currentPath).getLength();
    } catch (FileNotFoundException e) {
      Path archivedLogPath = findArchivedLog(currentPath, conf);
      // archivedLogPath can be null if unable to locate in archiveDir.
      if (archivedLogPath == null) {
        throw new FileNotFoundException("Couldn't find path: " + currentPath);
      }
      fileSize = fs.getContentSummary(archivedLogPath).getLength();
    }
    return fileSize;
  }
Instantiation method used by region servers
@param conf      configuration to use
@param fs        file system to use
@param manager   replication manager to ping to
@param server    the server for this region server
@param queueData the id and offsets of our replication queue
@param clusterId unique UUID for the cluster
@param metrics   metrics for replication source
hbase-server/src/main/java/org/apache/hadoop/hbase/replication/regionserver/ReplicationSource.java