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

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

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

    https://github.com/apache/drill/pull/1099#discussion_r164010530
  
    --- Diff: 
contrib/storage-hbase/src/test/java/org/apache/drill/hbase/TestOrderedBytesConvertFunctions.java
 ---
    @@ -54,7 +54,7 @@ public void testOrderedBytesDouble() throws Throwable {
     
       @Test
       public void testOrderedBytesDoubleConvertFrom() throws Throwable {
    -    
verifyPhysicalPlan("convert_from(binary_string('\\x31\\x80\\x00\\x00\\x00\\x00\\x00\\x00\\x01'),
 'DOUBLE_OB')", new Double(4.9e-324));
    +    
verifyPhysicalPlan("convert_from(binary_string('\\x31\\x80\\x00\\x00\\x00\\x00\\x00\\x00\\x01'),
 'DOUBLE_OB')", Double.valueOf(4.9e-324));
    --- End diff --
    
    For `Double` and `Float` there is no benefit using `valueOf()`, OK if used 
for consistency.


> Use valueOf method instead of constructor since valueOf has a higher 
> performance by caching frequently requested values.
> ------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DRILL-6106
>                 URL: https://issues.apache.org/jira/browse/DRILL-6106
>             Project: Apache Drill
>          Issue Type: Improvement
>            Reporter: Reudismam Rolim de Sousa
>            Priority: Minor
>
> Use valueOf method instead of constructor since valueOf has a higher 
> performance by caching frequently requested values.



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

Reply via email to