public static SnapshotRegionLocator create(Configuration conf, TableName table)
    throws IOException {
    Path workingDir = new Path(conf.get(getSnapshotManifestDirKey(table)));
    FileSystem fs = workingDir.getFileSystem(conf);
    SnapshotProtos.SnapshotDescription desc =
      SnapshotDescriptionUtils.readSnapshotInfo(fs, workingDir);
    SnapshotManifest manifest = SnapshotManifest.open(conf, fs, workingDir, desc);

    TableName tableName = manifest.getTableDescriptor().getTableName();
    TreeMap<byte[], HRegionReplicas> replicas = new TreeMap<>(Bytes.BYTES_COMPARATOR);
    List<HRegionLocation> rawLocations = new ArrayList<>();

    for (SnapshotProtos.SnapshotRegionManifest region : manifest.getRegionManifests()) {
      HBaseProtos.RegionInfo ri = region.getRegionInfo();
      byte[] key = ri.getStartKey().toByteArray();

      SnapshotHRegionLocation location = toLocation(ri, tableName);
      rawLocations.add(location);
      HRegionReplicas hrr = replicas.get(key);

      if (hrr == null) {
        hrr = new HRegionReplicas(location);
      } else {
        hrr.addReplica(location);
      }

      replicas.put(key, hrr);
    }

    return new SnapshotRegionLocator(tableName, replicas, rawLocations);
  }
{@link RegionLocator} built using the most recent full backup's snapshot manifest for a given
table. Useful for aligning any subsequent incremental backups along the same splits as the full
backup
hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/SnapshotRegionLocator.java