avro-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nkol...@apache.org
Subject [avro] branch master updated: AVRO-2450 log message about failure to load SnappyCodec (#565)
Date Mon, 01 Jul 2019 09:38:48 GMT
This is an automated email from the ASF dual-hosted git repository.

nkollar pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/avro.git


The following commit(s) were added to refs/heads/master by this push:
     new c7a9b93  AVRO-2450 log message about failure to load SnappyCodec (#565)
c7a9b93 is described below

commit c7a9b93246c6cccd4bfd210213141befc170990b
Author: Sean Busbey <busbey@apache.org>
AuthorDate: Mon Jul 1 04:38:43 2019 -0500

    AVRO-2450 log message about failure to load SnappyCodec (#565)
---
 lang/java/avro/src/main/java/org/apache/avro/file/CodecFactory.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lang/java/avro/src/main/java/org/apache/avro/file/CodecFactory.java b/lang/java/avro/src/main/java/org/apache/avro/file/CodecFactory.java
index 8af16f0..13833ca 100644
--- a/lang/java/avro/src/main/java/org/apache/avro/file/CodecFactory.java
+++ b/lang/java/avro/src/main/java/org/apache/avro/file/CodecFactory.java
@@ -22,6 +22,8 @@ import java.util.Map;
 import java.util.zip.Deflater;
 
 import org.apache.avro.AvroRuntimeException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * Encapsulates the ability to specify and configure a compression codec.
@@ -38,6 +40,8 @@ import org.apache.avro.AvroRuntimeException;
  * {@link #addCodec(String, CodecFactory)}.
  */
 public abstract class CodecFactory {
+  private static final Logger LOG = LoggerFactory.getLogger(CodecFactory.class);
+
   /** Null codec, for no compression. */
   public static CodecFactory nullCodec() {
     return NullCodec.OPTION;
@@ -64,7 +68,7 @@ public abstract class CodecFactory {
     try {
       return new SnappyCodec.Option();
     } catch (Throwable t) {
-      // snappy not available
+      LOG.debug("Snappy was not available", t);
       return null;
     }
   }


Mime
View raw message