You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by al...@apache.org on 2014/08/22 20:56:16 UTC
[1/3] git commit: Add missing license header
Repository: cassandra
Updated Branches:
refs/heads/cassandra-2.1.0 8da134377 -> 35cfa61c5
Add missing license header
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/e28e7bf2
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/e28e7bf2
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/e28e7bf2
Branch: refs/heads/cassandra-2.1.0
Commit: e28e7bf2b1a6bed1a4d38d86a1738cb8159c3f92
Parents: 200b802
Author: Sylvain Lebresne <sy...@datastax.com>
Authored: Fri Aug 22 17:07:25 2014 +0200
Committer: Sylvain Lebresne <sy...@datastax.com>
Committed: Fri Aug 22 17:07:25 2014 +0200
----------------------------------------------------------------------
.../LimitedLocalNodeFirstLocalBalancingPolicy.java | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/e28e7bf2/src/java/org/apache/cassandra/hadoop/cql3/LimitedLocalNodeFirstLocalBalancingPolicy.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/hadoop/cql3/LimitedLocalNodeFirstLocalBalancingPolicy.java b/src/java/org/apache/cassandra/hadoop/cql3/LimitedLocalNodeFirstLocalBalancingPolicy.java
index 3aa7df0..8949892 100644
--- a/src/java/org/apache/cassandra/hadoop/cql3/LimitedLocalNodeFirstLocalBalancingPolicy.java
+++ b/src/java/org/apache/cassandra/hadoop/cql3/LimitedLocalNodeFirstLocalBalancingPolicy.java
@@ -1,3 +1,20 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package org.apache.cassandra.hadoop.cql3;
import com.datastax.driver.core.Cluster;
[3/3] git commit: Merge branch 'cassandra-2.0' into cassandra-2.1.0
Posted by al...@apache.org.
Merge branch 'cassandra-2.0' into cassandra-2.1.0
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/35cfa61c
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/35cfa61c
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/35cfa61c
Branch: refs/heads/cassandra-2.1.0
Commit: 35cfa61c53c4caac680630e8a7e118b0d4692e17
Parents: 8da1343 a5617d6
Author: Aleksey Yeschenko <al...@apache.org>
Authored: Fri Aug 22 21:55:56 2014 +0300
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri Aug 22 21:55:56 2014 +0300
----------------------------------------------------------------------
----------------------------------------------------------------------
[2/3] git commit: Save source exception in CorruptBlockException
Posted by al...@apache.org.
Save source exception in CorruptBlockException
ninja patch by Pavel Yaskevich; ninja reviewed by Aleksey Yeschenko
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/a5617d68
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/a5617d68
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/a5617d68
Branch: refs/heads/cassandra-2.1.0
Commit: a5617d689c8feee40f9412c373d02c9f1770d359
Parents: e28e7bf
Author: Pavel Yaskevich <xe...@apache.org>
Authored: Fri Aug 22 21:52:11 2014 +0300
Committer: Aleksey Yeschenko <al...@apache.org>
Committed: Fri Aug 22 21:52:11 2014 +0300
----------------------------------------------------------------------
.../io/compress/CompressedRandomAccessReader.java | 2 +-
.../cassandra/io/compress/CorruptBlockException.java | 14 ++++++++++++--
2 files changed, 13 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/a5617d68/src/java/org/apache/cassandra/io/compress/CompressedRandomAccessReader.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/compress/CompressedRandomAccessReader.java b/src/java/org/apache/cassandra/io/compress/CompressedRandomAccessReader.java
index 131a4d6..64495b8 100644
--- a/src/java/org/apache/cassandra/io/compress/CompressedRandomAccessReader.java
+++ b/src/java/org/apache/cassandra/io/compress/CompressedRandomAccessReader.java
@@ -119,7 +119,7 @@ public class CompressedRandomAccessReader extends RandomAccessReader
}
catch (IOException e)
{
- throw new CorruptBlockException(getPath(), chunk);
+ throw new CorruptBlockException(getPath(), chunk, e);
}
if (metadata.parameters.getCrcCheckChance() > FBUtilities.threadLocalRandom().nextDouble())
http://git-wip-us.apache.org/repos/asf/cassandra/blob/a5617d68/src/java/org/apache/cassandra/io/compress/CorruptBlockException.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/compress/CorruptBlockException.java b/src/java/org/apache/cassandra/io/compress/CorruptBlockException.java
index 60b4d1f..bcce6b9 100644
--- a/src/java/org/apache/cassandra/io/compress/CorruptBlockException.java
+++ b/src/java/org/apache/cassandra/io/compress/CorruptBlockException.java
@@ -23,11 +23,21 @@ public class CorruptBlockException extends IOException
{
public CorruptBlockException(String filePath, CompressionMetadata.Chunk chunk)
{
- this(filePath, chunk.offset, chunk.length);
+ this(filePath, chunk, null);
+ }
+
+ public CorruptBlockException(String filePath, CompressionMetadata.Chunk chunk, Throwable cause)
+ {
+ this(filePath, chunk.offset, chunk.length, cause);
}
public CorruptBlockException(String filePath, long offset, int length)
{
- super(String.format("(%s): corruption detected, chunk at %d of length %d.", filePath, offset, length));
+ this(filePath, offset, length, null);
+ }
+
+ public CorruptBlockException(String filePath, long offset, int length, Throwable cause)
+ {
+ super(String.format("(%s): corruption detected, chunk at %d of length %d.", filePath, offset, length), cause);
}
}