Github user kkhatua commented on a diff in the pull request:

    https://github.com/apache/drill/pull/1197#discussion_r179557189
  
    --- Diff: 
exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/OperatorWrapper.java
 ---
    @@ -190,8 +223,59 @@ public void addSummary(TableBuilder tb, 
HashMap<String, Long> majorFragmentBusyT
         tb.appendFormattedInteger(recordSum);
     
         final ImmutablePair<OperatorProfile, Integer> peakMem = 
Collections.max(opList, Comparators.operatorPeakMemory);
    -    tb.appendBytes(Math.round(memSum / size));
    -    tb.appendBytes(peakMem.getLeft().getPeakLocalMemoryAllocated());
    +
    +    //Inject spill-to-disk attributes
    +    Map<String, String> avgSpillMap = null;
    +    Map<String, String> maxSpillMap = null;
    +    if (hasSpilledToDisk) {
    +      avgSpillMap = new HashMap<>();
    +      //Average SpillCycle
    +      float avgSpillCycle = (float) spillCycleSum/size;
    --- End diff --
    
    My bad. I was thinking the sum was a long. I'll fix this.


---

Reply via email to