accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ujustgotbi...@apache.org
Subject [5/6] accumulo git commit: Merge branch '1.5' into 1.6
Date Fri, 10 Apr 2015 01:15:45 GMT
Merge branch '1.5' into 1.6


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

Branch: refs/heads/1.6
Commit: 6fa2090b6fa2c3189ed6b20c6b1f2506451cc97c
Parents: 6605ad4 73ce9cf
Author: Bill Slacum <ujustgotbilld@apache.org>
Authored: Thu Apr 9 19:50:18 2015 -0400
Committer: Bill Slacum <ujustgotbilld@apache.org>
Committed: Thu Apr 9 19:50:18 2015 -0400

----------------------------------------------------------------------
 .../org/apache/accumulo/core/data/Mutation.java | 34 +++++++++++++++++---
 .../apache/accumulo/core/data/MutationTest.java | 28 ++++++++++++++++
 2 files changed, 57 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/6fa2090b/core/src/main/java/org/apache/accumulo/core/data/Mutation.java
----------------------------------------------------------------------
diff --cc core/src/main/java/org/apache/accumulo/core/data/Mutation.java
index 34d8df1,81ad531..233a12e
--- a/core/src/main/java/org/apache/accumulo/core/data/Mutation.java
+++ b/core/src/main/java/org/apache/accumulo/core/data/Mutation.java
@@@ -583,25 -705,13 +597,25 @@@ public class Mutation implements Writab
  
    @Override
    public int hashCode() {
-     return toThrift().hashCode();
+     return toThrift(false).hashCode();
    }
  
 +  /**
 +   * Checks if this mutation equals another. This method may be removed in a future API
revision in favor of {@link #equals(Object)}. See ACCUMULO-1627 for more
 +   * information.
 +   *
 +   * @param m
 +   *          mutation
 +   * @return true if the given mutation equals this one, false otehrwise
 +   */
    public boolean equals(Mutation m) {
 +    return this.equals((Object) m);
 +  }
 +
 +  private boolean equalMutation(Mutation m) {
-     serialize();
-     m.serialize();
-     if (Arrays.equals(row, m.row) && entries == m.entries && Arrays.equals(data,
m.data)) {
+     byte[] myData = serializedSnapshot();
+     byte[] otherData = m.serializedSnapshot();
+     if (Arrays.equals(row, m.row) && entries == m.entries && Arrays.equals(myData,
otherData)) {
        if (values == null && m.values == null)
          return true;
  


Mime
View raw message