public Path getAvailablePath(FileSystem fs) throws IOException {
    for (int i = 0; i < locations.length; ++i) {
      if (fs.exists(locations[i])) {
        return locations[i];
      }
    }
    throw new FileNotFoundException(toString());
  }
Returns the path of the first available link.
hbase-server/src/main/java/org/apache/hadoop/hbase/io/FileLink.java