aho135 commented on code in PR #19627:
URL: https://github.com/apache/druid/pull/19627#discussion_r3856070373


##########
processing/src/main/java/org/apache/druid/query/groupby/epinephelinae/SpillingGrouper.java:
##########
@@ -249,7 +249,13 @@ public void reset()
   public void close()
   {
     perQueryStats.dictionarySize(getDictionarySizeEstimate());
-    perQueryStats.maxMergeBufferUsedBytes(getMaxMergeBufferUsedBytes());
+    final long sliceUsedBytes = getMaxMergeBufferUsedBytes();
+    perQueryStats.addMergeBufferUsedBytes(sliceUsedBytes);
+    if (grouper.isInitialized()) {

Review Comment:
   Done in 3aea492. Folded both the merge-buffer-usage and spill-proximity 
reporting under a single `grouper.isInitialized()` block and removed the now 
single-use private `getMaxMergeBufferUsedBytes()` helper. Behavior-preserving — 
the uninitialized path previously just did an inert 
`addMergeBufferUsedBytes(0L)`.



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