private boolean allFilesExpired(final List<HStoreFile> storeFiles) {
    if (storeFiles == null || storeFiles.isEmpty()) {
      return false;
    }
    long cfTtl = this.storeConfigInfo.getStoreFileTtl();
    if (cfTtl == Long.MAX_VALUE) {
      return false; // minversion might be set, cannot delete old files
    }
    long timestampCutoff = EnvironmentEdgeManager.currentTime() - cfTtl;
    for (HStoreFile storeFile : storeFiles) {
      // Check store file is not empty and has not expired
      if (
        storeFile.getReader().getMaxTimestamp() >= timestampCutoff
          && storeFile.getReader().getEntries() != 0
      ) {
        return false;
      }
    }
    return true;
  }
Selects the compaction of a single stripe using default policy.
@param sfs          Files.
@param allFilesOnly Whether a compaction of all-or-none files is needed.
@return The resulting selection.
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/StripeCompactionPolicy.java