private List<SettleCompactionTask> createTask(List<SettleTaskResource> settleTaskResourceList) {
    List<SettleCompactionTask> tasks = new ArrayList<>();
    for (SettleTaskResource settleTaskResource : settleTaskResourceList) {
      if (settleTaskResource.isEmpty()) {
        continue;
      }
      SettleCompactionTask task =
          new SettleCompactionTask(
              timePartition,
              tsFileManager,
              settleTaskResource.getFullyDirtyResources(),
              settleTaskResource.getPartiallyDirtyResources(),
              isSeq,
              createCompactionPerformer(),
              tsFileManager.getNextCompactionTaskId());
      tasks.add(task);
    }
    return tasks;
  }
Check whether the device is completely deleted by mods or not.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/compaction/selector/impl/SettleSelectorImpl.java