You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/02/12 04:52:32 UTC

[GitHub] [iotdb] JackieTien97 commented on a change in pull request #5046: [To rel/0.12] [IOTDB-2532] Query with align by device can't get value after clear cache

JackieTien97 commented on a change in pull request #5046:
URL: https://github.com/apache/iotdb/pull/5046#discussion_r805118110



##########
File path: server/src/main/java/org/apache/iotdb/db/qp/physical/crud/RawDataQueryPlan.java
##########
@@ -54,6 +56,19 @@ public IExpression getExpression() {
 
   public void setExpression(IExpression expression) throws QueryProcessException {
     this.expression = expression;
+    updateDeviceMeasurementsUsingExpression(expression);
+  }

Review comment:
       * `setExpression` will be called twice, once in `transformFilterOperatorToExpression` of `QueryOperator` which generating logical plan, once in `QueryRouter` after optimizing this expression. Although it won't make it it doesn't affect its correctness, the performance may be worse than before.
   * In align by device query, the `deviceToMeasurements` should only contains current device, in your current implementation, all the devices will be saved in `deviceToMeasurements`, even if the devices that has been traversed.
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org