cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From slebre...@apache.org
Subject git commit: Fix compression options validation
Date Fri, 14 Dec 2012 15:53:30 GMT
Updated Branches:
  refs/heads/cassandra-1.1 5a6981eb6 -> 4885bfccf


Fix compression options validation

patch by slebresne; reviewed by iamaleksey for CASSANDRA-5066


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/4885bfcc
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/4885bfcc
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/4885bfcc

Branch: refs/heads/cassandra-1.1
Commit: 4885bfccf1841def0c86b46302133cf2924d7acd
Parents: 5a6981e
Author: Sylvain Lebresne <sylvain@datastax.com>
Authored: Fri Dec 14 16:52:29 2012 +0100
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Fri Dec 14 16:52:29 2012 +0100

----------------------------------------------------------------------
 CHANGES.txt                                        |    2 +-
 .../io/compress/CompressionParameters.java         |    4 ++++
 2 files changed, 5 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/4885bfcc/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index c9f1098..03b62c8 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -7,7 +7,7 @@
  * Fall back to old describe_splits if d_s_ex is not available (CASSANDRA-4803)
  * Improve error reporting when streaming ranges fail (CASSANDRA-5009)
  * cqlsh: fix timestamp formatting on some platforms (CASSANDRA-5046)
- * Fix ALTER TABLE overriding compression options with defaults (CASSANDRA-4996)
+ * Fix ALTER TABLE overriding compression options with defaults (CASSANDRA-4996, 5066)
  * Avoid error opening data file on startup (CASSANDRA-4984)
  * Fix wrong index_options in cli 'show schema' (CASSANDRA-5008)
  * Allow overriding number of available processor (CASSANDRA-4790)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/4885bfcc/src/java/org/apache/cassandra/io/compress/CompressionParameters.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/compress/CompressionParameters.java b/src/java/org/apache/cassandra/io/compress/CompressionParameters.java
index c8a15d7..9be71f6 100644
--- a/src/java/org/apache/cassandra/io/compress/CompressionParameters.java
+++ b/src/java/org/apache/cassandra/io/compress/CompressionParameters.java
@@ -100,7 +100,11 @@ public class CompressionParameters
     private static ICompressor createCompressor(Class<? extends ICompressor> compressorClass,
Map<String, String> compressionOptions) throws ConfigurationException
     {
         if (compressorClass == null)
+        {
+            if (!compressionOptions.isEmpty())
+                throw new ConfigurationException("Unknown compression options (" + compressionOptions.keySet()
+ ") since no compression class found");
             return null;
+        }
 
         try
         {


Mime
View raw message