public static Set<String> listAllFilesNames(Map<String, HRegion> onlineRegions) {
    Set<String> files = new HashSet<>();
    onlineRegions.values().forEach(r -> {
      r.getStores().forEach(s -> {
        s.getStorefiles().forEach(f -> files.add(f.getPath().getName()));
      });
    });
    return files;
  }
Because of the region splitting, it's possible that the split key locate in the middle of a
block. So it's possible that both the daughter regions load the same block from their parent
HFile. When pread, we don't force the read to read all of the next block header. So when two
threads try to cache the same block, it's possible that one thread read all of the next block
header but the other one didn't. if the already cached block hasn't next block header but the
new block to cache has, then we can replace the existing block with the new block for better
performance.(HBASE-20447)
@param blockCache BlockCache to check
@param cacheKey   the block cache key
@param newBlock   the new block which try to put into the block cache.
@return true means need to replace existing block with new block for the same block cache key.
        false means just keep the existing block.
hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/BlockCacheUtil.java