hmsonline / storm-cassandra-cql

Storm Cassandra Bridge built on CQL
Apache License 2.0
43 stars 38 forks source link

Add LZ4 Dependency? #41

Closed bflad closed 9 years ago

bflad commented 9 years ago

Downstream projects throw a WARN on startup because the Datastax Cassandra Java Driver (at least 2.1.x) throws it automatically if the LZ4 library isn't available, even if LZ4 compression isn't used. Since we allow the compression to be set when building the cluster configuration, should we include the dependency here so downstream projects don't need to explicitly declare it?

Here's an example WARN log:

WARN  [2015-02-05 20:56:54,568] com.datastax.driver.core.FrameCompressor: Error loading LZ4 library (java.lang.NoSuchMethodError: net.jpountz.lz4.LZ4Factory.fastDecompressor()Lnet/jpountz/lz4/LZ4FastDecompressor;). LZ4 compression will not be available for the protocol.

Example POM entry that would fix it:

<dependency>
    <groupId>net.jpountz.lz4</groupId>
    <artifactId>lz4</artifactId>
    <version>1.2.0</version>
</dependency>

Please let me know if you'd like me to submit a PR here. Personally, I think upstream shouldn't be throwing a WARN for an optional dependency when its not used.

boneill42 commented 9 years ago

I like the idea. I'll drop the dependency in.