jihoonson commented on a change in pull request #5471: Implement force push 
down for nested group by query
URL: https://github.com/apache/incubator-druid/pull/5471#discussion_r204894682
 
 

 ##########
 File path: 
processing/src/main/java/io/druid/query/groupby/GroupByQueryQueryToolChest.java
 ##########
 @@ -162,10 +162,11 @@ public GroupByQueryQueryToolChest(
       Map<String, Object> context
   )
   {
+    if (isNestedQueryPushDown(query, groupByStrategy)) {
 
 Review comment:
   I believe that once `isNestedQueryPushDown(query, groupByStrategy)` returns 
false, it never changes no matter how many times we call it in this method. 
Since `mergeGroupByResults()` can call internally itself again if `dataSource` 
is a `queryDataSource` 
(https://github.com/apache/incubator-druid/pull/5471/files#diff-631de2c7bba9484c3ffd4a58b4cf691eR193),
 this might be checked again and again redundantly. I would suggest to add new 
methods which is called in `mergeGroupByResults()` like below:
   
   ```
   mergeGroupByResults() -> mergeGroupByResultsWithoutPushDown() -> 
mergeGroupByResultsWithoutPushDown() if needed ...
                        |-> mergeGroupByResultsWithPushDown()
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@druid.apache.org
For additional commands, e-mail: dev-h...@druid.apache.org

Reply via email to