cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alek...@apache.org
Subject [2/3] git commit: Merge branch 'cassandra-2.0' into cassandra-2.1
Date Mon, 31 Mar 2014 10:10:48 GMT
Merge branch 'cassandra-2.0' into cassandra-2.1

Conflicts:
	src/java/org/apache/cassandra/db/BatchlogManager.java


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

Branch: refs/heads/cassandra-2.1
Commit: f6daf4e30767c8a4891b88116108db54387847f9
Parents: 6844462 d049017
Author: Aleksey Yeschenko <aleksey@apache.org>
Authored: Mon Mar 31 13:04:10 2014 +0300
Committer: Aleksey Yeschenko <aleksey@apache.org>
Committed: Mon Mar 31 13:04:10 2014 +0300

----------------------------------------------------------------------
 .../org/apache/cassandra/config/CFMetaData.java |  3 ++-
 .../apache/cassandra/db/BatchlogManager.java    | 22 ++++++++++----------
 2 files changed, 13 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/f6daf4e3/src/java/org/apache/cassandra/config/CFMetaData.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/cassandra/blob/f6daf4e3/src/java/org/apache/cassandra/db/BatchlogManager.java
----------------------------------------------------------------------
diff --cc src/java/org/apache/cassandra/db/BatchlogManager.java
index 8024769,2e09285..603b9d8
--- a/src/java/org/apache/cassandra/db/BatchlogManager.java
+++ b/src/java/org/apache/cassandra/db/BatchlogManager.java
@@@ -147,9 -148,9 +146,9 @@@ public class BatchlogManager implement
  
          try
          {
 -            out.writeInt(mutations.size());
 -            for (RowMutation rm : mutations)
 -                RowMutation.serializer.serialize(rm, out, MessagingService.VERSION_12);
 +            buf.writeInt(mutations.size());
 +            for (Mutation mutation : mutations)
-                 Mutation.serializer.serialize(mutation, buf, VERSION);
++                Mutation.serializer.serialize(mutation, buf, MessagingService.VERSION_12);
          }
          catch (IOException e)
          {
@@@ -250,14 -252,14 +250,14 @@@
          DataInputStream in = new DataInputStream(ByteBufferUtil.inputStream(data));
          int size = in.readInt();
          for (int i = 0; i < size; i++)
-             replaySerializedMutation(Mutation.serializer.deserialize(in, VERSION), writtenAt,
rateLimiter);
 -            replaySerializedMutation(RowMutation.serializer.deserialize(in, version), writtenAt,
version, rateLimiter);
++            replaySerializedMutation(Mutation.serializer.deserialize(in, version), writtenAt,
version, rateLimiter);
      }
  
      /*
       * We try to deliver the mutations to the replicas ourselves if they are alive and only
resort to writing hints
       * when a replica is down or a write request times out.
       */
-     private void replaySerializedMutation(Mutation mutation, long writtenAt, RateLimiter
rateLimiter)
 -    private void replaySerializedMutation(RowMutation mutation, long writtenAt, int version,
RateLimiter rateLimiter)
++    private void replaySerializedMutation(Mutation mutation, long writtenAt, int version,
RateLimiter rateLimiter)
      {
          int ttl = calculateHintTTL(mutation, writtenAt);
          if (ttl <= 0)
@@@ -266,7 -268,7 +266,7 @@@
          Set<InetAddress> liveEndpoints = new HashSet<>();
          String ks = mutation.getKeyspaceName();
          Token<?> tk = StorageService.getPartitioner().getToken(mutation.key());
-         int mutationSize = (int) Mutation.serializer.serializedSize(mutation, VERSION);
 -        int mutationSize = (int) RowMutation.serializer.serializedSize(mutation, version);
++        int mutationSize = (int) Mutation.serializer.serializedSize(mutation, version);
  
          for (InetAddress endpoint : Iterables.concat(StorageService.instance.getNaturalEndpoints(ks,
tk),
                                                       StorageService.instance.getTokenMetadata().pendingEndpointsFor(tk,
ks)))


Mime
View raw message