public int comparePriority(TimePartitionInfo timePartitionInfo) {
    int cmp = Boolean.compare(isActive, timePartitionInfo.isActive);
    if (cmp != 0) {
      return cmp;
    }
    cmp = Long.compare(partitionId, timePartitionInfo.partitionId);
    if (cmp != 0) {
      return cmp;
    }
    return Long.compare(lastSystemFlushTime, timePartitionInfo.lastSystemFlushTime);
  }
Time partition info records necessary info of a time partition for a data region
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/rescon/memory/TimePartitionInfo.java