cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sn...@apache.org
Subject [1/6] cassandra git commit: Include table name in "Cannot get comparator" exception
Date Sat, 30 Jul 2016 09:34:26 GMT
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-3.0 8868b744c -> 1823c84b8
  refs/heads/cassandra-3.9 8e775eaaf -> 5fb6f9585
  refs/heads/trunk a123e984c -> 4ad335348


Include table name in "Cannot get comparator" exception

patch by sankalp kohli; reviewed by Robert Stupp for CASSANDRA-12181


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

Branch: refs/heads/cassandra-3.0
Commit: 1823c84b827ff5f38862757db58001105f1d753f
Parents: 8868b74
Author: sankalp kohli <sankalp@apple.com>
Authored: Sat Jul 30 11:30:01 2016 +0200
Committer: Robert Stupp <snazy@snazy.de>
Committed: Sat Jul 30 11:30:01 2016 +0200

----------------------------------------------------------------------
 .../apache/cassandra/db/ColumnFamilyStore.java  | 24 ++++++++++++++------
 1 file changed, 17 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/1823c84b/src/java/org/apache/cassandra/db/ColumnFamilyStore.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/db/ColumnFamilyStore.java b/src/java/org/apache/cassandra/db/ColumnFamilyStore.java
index 1e52b13..400fd36 100644
--- a/src/java/org/apache/cassandra/db/ColumnFamilyStore.java
+++ b/src/java/org/apache/cassandra/db/ColumnFamilyStore.java
@@ -1225,13 +1225,23 @@ public class ColumnFamilyStore implements ColumnFamilyStoreMBean
     {
         long start = System.nanoTime();
         Memtable mt = data.getMemtableFor(opGroup, replayPosition);
-        long timeDelta = mt.put(update, indexer, opGroup);
-        DecoratedKey key = update.partitionKey();
-        maybeUpdateRowCache(key);
-        metric.samplers.get(Sampler.WRITES).addSample(key.getKey(), key.hashCode(), 1);
-        metric.writeLatency.addNano(System.nanoTime() - start);
-        if(timeDelta < Long.MAX_VALUE)
-            metric.colUpdateTimeDeltaHistogram.update(timeDelta);
+        try
+        {
+            long timeDelta = mt.put(update, indexer, opGroup);
+            DecoratedKey key = update.partitionKey();
+            maybeUpdateRowCache(key);
+            metric.samplers.get(Sampler.WRITES).addSample(key.getKey(), key.hashCode(), 1);
+            metric.writeLatency.addNano(System.nanoTime() - start);
+            if(timeDelta < Long.MAX_VALUE)
+                metric.colUpdateTimeDeltaHistogram.update(timeDelta);
+        }
+        catch (RuntimeException e)
+        {
+            throw new RuntimeException(e.getMessage()
+                                                     + " for ks: "
+                                                     + keyspace.getName() + ", table: " +
name, e);
+        }
+
     }
 
     /**


Mime
View raw message