SteNicholas commented on issue #2043:
URL: 
https://github.com/apache/incubator-celeborn/issues/2043#issuecomment-1780536238

   @shuai-xu, why should it support configurable checksum in `Lz4Decompressor`? 
IMO, `XXHashFactory#fastestInstance` would determine to use which instance 
according to environment.
   ```
   /**
      * Returns the fastest available {@link XXHashFactory} instance. If the 
class
      * loader is the system class loader and if the
      * {@link #nativeInstance() native instance} loads successfully, then the
      * {@link #nativeInstance() native instance} is returned, otherwise the
      * {@link #fastestJavaInstance() fastest Java instance} is returned.
      * <p>
      * Please read {@link #nativeInstance() javadocs of nativeInstance()} 
before
      * using this method.
      *
      * @return the fastest available {@link XXHashFactory} instance.
      */
     public static XXHashFactory fastestInstance() {
       if (Native.isLoaded()
           || Native.class.getClassLoader() == 
ClassLoader.getSystemClassLoader()) {
         try {
           return nativeInstance();
         } catch (Throwable t) {
           return fastestJavaInstance();
         }
       } else {
         return fastestJavaInstance();
       }
     }
   ```


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

Reply via email to