[ 
https://issues.apache.org/jira/browse/DRILL-6463?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16505436#comment-16505436
 ] 

ASF GitHub Bot commented on DRILL-6463:
---------------------------------------

gparai commented on a change in pull request #1303: DRILL-6463 : Fix integer 
overflow in MockGroupScanPOP
URL: https://github.com/apache/drill/pull/1303#discussion_r193912576
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/ScanStats.java
 ##########
 @@ -23,27 +23,27 @@
 
   public static final ScanStats ZERO_RECORD_TABLE = new 
ScanStats(GroupScanProperty.EXACT_ROW_COUNT, 0, 1, 1);
 
-  private final long recordCount;
-  private final float cpuCost;
-  private final float diskCost;
+  private final double recordCount;
+  private final double cpuCost;
+  private final double diskCost;
   private final GroupScanProperty property;
 
-  public ScanStats(GroupScanProperty property, long recordCount, float 
cpuCost, float diskCost) {
+  public ScanStats(GroupScanProperty property, double recordCount, double 
cpuCost, double diskCost) {
 
 Review comment:
   Yes, you are correct. There are more examples of where we should do so e.g. 
HBaseGroupScan. However, the original JIRA was to fix the integer overflow so I 
skipped these changes. I will create another JIRA to address these issues.

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


> ProfileParser cannot parse costs when using MockScanBatch
> ---------------------------------------------------------
>
>                 Key: DRILL-6463
>                 URL: https://issues.apache.org/jira/browse/DRILL-6463
>             Project: Apache Drill
>          Issue Type: Bug
>    Affects Versions: 1.13.0
>            Reporter: Gautam Kumar Parai
>            Assignee: Gautam Kumar Parai
>            Priority: Major
>              Labels: ready-to-commit
>             Fix For: 1.14.0
>
>
> One of the unit testHashAggrSecondaryTertiarySpill() runs into this issue 
> although the issue is generic. It happens due to cost being stored in an int 
> which overflows with big enough rows/data size and becomes negative. This 
> causes the Profile parser to error out on seeing negative costs.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to