private void controlCompactionForBlobStore(PartitionId partitionId, boolean enable) {
    if (!controlCompactionForBlobStore.apply(partitionId, enable)) {
      String message = "Failed to " + (enable ? "enable" : "disable") + " compaction for partition: " + partitionId;
      logger.error(message);
      throw new IllegalStateException(message);
    } else {
      logger.info("Compaction " + (enable ? "enabled" : "disabled") + " for partition: " + partitionId);
    }
  }
Controls the compaction for the blob store. Checks if the operation is successful and throws an exception if not.
@param partitionId The partition ID for which to control compaction.
@param enable true to enable compaction, false to disable it.
ambry-store/src/main/java/com/github/ambry/store/BootstrapSessionManager.java