private List<AggregationDescriptor> getAggregationDescriptors(PlanNode planNode) {
    List<AggregationDescriptor> descriptorList = null;
    if (planNode instanceof SeriesAggregationSourceNode) {
      descriptorList = ((SeriesAggregationSourceNode) planNode).getAggregationDescriptorList();
    } else if (planNode instanceof AggregationNode) {
      descriptorList = ((AggregationNode) planNode).getAggregationDescriptorList();
    } else if (planNode instanceof SlidingWindowAggregationNode) {
      descriptorList = ((SlidingWindowAggregationNode) planNode).getAggregationDescriptorList();
    } else if (planNode instanceof RawDataAggregationNode) {
      descriptorList = ((RawDataAggregationNode) planNode).getAggregationDescriptorList();
    }
    return descriptorList;
  }
aggregation align by device, and aggregation is `count_if` or `diff`, or aggregation used with
group by parameter (session, variation, count), use the old aggregation logic
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/planner/distribution/SourceRewriter.java