songwdfu commented on code in PR #16454:
URL: https://github.com/apache/pinot/pull/16454#discussion_r2246012132


##########
pinot-core/src/main/java/org/apache/pinot/core/query/aggregation/groupby/AggregationGroupByResult.java:
##########
@@ -51,6 +51,15 @@ public Iterator<GroupKeyGenerator.GroupKey> 
getGroupKeyIterator() {
     return _groupKeyGenerator.getGroupKeys();
   }
 
+  /**
+   * Clear and trim DictionaryBasedGroupKeyGenerator after use
+   */
+  public void clearAndTrimGroupKeyGenerator() {

Review Comment:
   With it implementing `AutoClosable`, we need to wrap the 
DictionaryBasedGroupKeyGenerator with try-with-resource blocks if we want it to 
auto-close, right? Since it could be closed either after segment trim or 
combine depending on the branches, would calling close() manually make things 
easier?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to