You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2021/02/22 18:35:57 UTC

[GitHub] [incubator-pinot] Jackie-Jiang commented on a change in pull request #6593: Directly store values in GroupKey and avoid ser/de

Jackie-Jiang commented on a change in pull request #6593:
URL: https://github.com/apache/incubator-pinot/pull/6593#discussion_r580493813



##########
File path: pinot-core/src/main/java/org/apache/pinot/core/query/aggregation/groupby/NoDictionarySingleColumnGroupKeyGenerator.java
##########
@@ -369,6 +388,146 @@ public boolean hasNext() {
 
     @Override
     public GroupKey next() {
+      Object2IntMap.Entry entry = _iterator.next();
+      _groupKey._groupId = entry.getIntValue();
+      _groupKey._keys = new Object[]{entry.getKey()};
+      return _groupKey;
+    }
+
+    @Override
+    public void remove() {
+      throw new UnsupportedOperationException();
+    }
+  }
+
+  private static class IntStringGroupKeyIterator implements Iterator<StringGroupKey> {

Review comment:
       PQL engine is using string as the key to group the results (it does not require sorting on per-group-by column basis, but always sort on aggregation values). We can remove these classes once deprecating PQL.




----------------------------------------------------------------
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.

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org