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

    https://github.com/apache/accumulo/pull/106#discussion_r65523717
  
    --- Diff: 
core/src/main/java/org/apache/accumulo/core/file/rfile/bcfile/Compression.java 
---
    @@ -81,38 +89,60 @@ public void flush() throws IOException {
        * Compression algorithms.
        */
       public static enum Algorithm {
    +
         LZO(COMPRESSION_LZO) {
    -      private transient boolean checked = false;
    +      private AtomicBoolean checked = new AtomicBoolean(false);
           private static final String defaultClazz = 
"org.apache.hadoop.io.compress.LzoCodec";
           private transient CompressionCodec codec = null;
     
    +      /**
    +       * Configuration option for LZO buffer size
    +       */
    +      private static final String BUFFER_SIZE_OPT = 
"io.compression.codec.lzo.buffersize";
    +
    +      /**
    +       * Default buffer size
    +       */
    +      private static final int DEFAULT_BUFFER_SIZE = 64 * 1024;
    +
           @Override
    -      public synchronized boolean isSupported() {
    --- End diff --
    
    The code is now predicated upon the static initializer. I think this goes 
to Keith's point that we not only need a comment block to dictate the changes 
better, but additional tests  to make this obvious. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to