You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by no...@apache.org on 2017/01/03 18:43:42 UTC

[1/2] lucene-solr:branch_6x: SOLR-9915: PeerSync alreadyInSync check is not backwards compatible and results in full replication during a rolling restart

Repository: lucene-solr
Updated Branches:
  refs/heads/branch_6x 77828f764 -> 122fa6cf6


SOLR-9915: PeerSync alreadyInSync check is not backwards compatible and results in full replication during a rolling restart


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/1b9564a5
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/1b9564a5
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/1b9564a5

Branch: refs/heads/branch_6x
Commit: 1b9564a5dccb2938586f2f82f963bd1534b002cd
Parents: 77828f7
Author: Noble Paul <no...@apache.org>
Authored: Wed Jan 4 04:38:51 2017 +1030
Committer: Noble Paul <no...@apache.org>
Committed: Wed Jan 4 05:13:12 2017 +1030

----------------------------------------------------------------------
 solr/core/src/java/org/apache/solr/update/PeerSync.java | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/1b9564a5/solr/core/src/java/org/apache/solr/update/PeerSync.java
----------------------------------------------------------------------
diff --git a/solr/core/src/java/org/apache/solr/update/PeerSync.java b/solr/core/src/java/org/apache/solr/update/PeerSync.java
index 1f61a56..12ba7ae 100644
--- a/solr/core/src/java/org/apache/solr/update/PeerSync.java
+++ b/solr/core/src/java/org/apache/solr/update/PeerSync.java
@@ -335,9 +335,15 @@ public class PeerSync  {
     for (;;) {
       ShardResponse srsp = shardHandler.takeCompletedOrError();
       if (srsp == null) break;
+
+      Object replicaFingerprint = srsp.getSolrResponse().getResponse().get("fingerprint");
+      if (replicaFingerprint == null) {
+        log.warn("Replica did not return a fingerprint - possibly an older Solr version");
+        continue;
+      }
       
       try {
-        IndexFingerprint otherFingerprint = IndexFingerprint.fromObject(srsp.getSolrResponse().getResponse().get("fingerprint"));
+        IndexFingerprint otherFingerprint = IndexFingerprint.fromObject(replicaFingerprint);
         IndexFingerprint ourFingerprint = IndexFingerprint.getFingerprint(core, Long.MAX_VALUE);
         if(IndexFingerprint.compare(otherFingerprint, ourFingerprint) == 0) {
           log.info("We are already in sync. No need to do a PeerSync ");


[2/2] lucene-solr:branch_6x: SOLR-9915: PeerSync alreadyInSync check is not backwards compatible and results in full replication during a rolling restart

Posted by no...@apache.org.
SOLR-9915: PeerSync alreadyInSync check is not backwards compatible and results in full replication during a rolling restart


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/122fa6cf
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/122fa6cf
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/122fa6cf

Branch: refs/heads/branch_6x
Commit: 122fa6cf64a56dd5ab5aff84f7f5c9a1305bde4e
Parents: 1b9564a
Author: Noble Paul <no...@apache.org>
Authored: Wed Jan 4 05:13:28 2017 +1030
Committer: Noble Paul <no...@apache.org>
Committed: Wed Jan 4 05:13:28 2017 +1030

----------------------------------------------------------------------
 solr/CHANGES.txt | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/122fa6cf/solr/CHANGES.txt
----------------------------------------------------------------------
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 8685d57..09bc1aa 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -299,6 +299,9 @@ Other Changes
 
 * SOLR-9448: providing a test to workaround a differently named uniqueKey field (Mikhail Khludnev)
 
+* SOLR-9915: PeerSync alreadyInSync check is not backwards compatible and results in full replication during a rolling restart
+  (Tim Owen via noble)
+
 ==================  6.3.0 ==================
 
 Consult the LUCENE_CHANGES.txt file for additional, low level, changes in this release.