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

ASF GitHub Bot commented on HADOOP-15033:
-----------------------------------------

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

    https://github.com/apache/hadoop/pull/291#discussion_r157756596
  
    --- Diff: 
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/DataChecksum.java
 ---
    @@ -70,6 +74,24 @@ public static Type valueOf(int id) {
         }
       }
     
    +  private static final MethodHandle NEW_CRC32C_MH;
    +  static {
    --- End diff --
    
    I'd like this to all be on demand, so that the introspection is only done 
if needed, which allows the exception to be thrown at the right point.
    
    Also, could we just back off from failing here at all, just log, track that 
the operation failed (so no attempt is repeated), and then fall back to the 
older mechanisms. I don't want things to overreact here


> Use java.util.zip.CRC32C for Java 9 and above
> ---------------------------------------------
>
>                 Key: HADOOP-15033
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15033
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: performance, util
>    Affects Versions: 3.0.0
>            Reporter: Dmitry Chuyko
>              Labels: Java9, common, jdk9
>         Attachments: HADOOP-15033.001.patch, HADOOP-15033.001.patch, 
> HADOOP-15033.002.patch, HADOOP-15033.003.patch, HADOOP-15033.003.patch, 
> HADOOP-15033.004.patch
>
>
> java.util.zip.CRC32C implementation is available since Java 9.
> https://docs.oracle.com/javase/9/docs/api/java/util/zip/CRC32C.html
> Platform specific assembler intrinsics make it more effective than any pure 
> Java implementation.
> Hadoop is compiled against Java 8 but class constructor may be accessible 
> with method handle on 9 to instances implementing Checksum in runtime.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-issues-h...@hadoop.apache.org

Reply via email to