You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by dw...@apache.org on 2021/03/10 09:48:20 UTC

[lucene] 02/04: LUCENE-8692: add additional logging to Solr test that first surfaced bug

This is an automated email from the ASF dual-hosted git repository.

dweiss pushed a commit to branch jira/LUCENE-8692
in repository https://gitbox.apache.org/repos/asf/lucene.git

commit 2b28d9d9d0cdc35dfdc202f23a9ef1d27b2a6083
Author: Chris Hostetter <ho...@apache.org>
AuthorDate: Tue Mar 5 16:02:48 2019 -0700

    LUCENE-8692: add additional logging to Solr test that first surfaced bug
---
 solr/core/src/test/org/apache/solr/cloud/LeaderTragicEventTest.java | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/solr/core/src/test/org/apache/solr/cloud/LeaderTragicEventTest.java b/solr/core/src/test/org/apache/solr/cloud/LeaderTragicEventTest.java
index 9bb44f4..4a6c223 100644
--- a/solr/core/src/test/org/apache/solr/cloud/LeaderTragicEventTest.java
+++ b/solr/core/src/test/org/apache/solr/cloud/LeaderTragicEventTest.java
@@ -84,11 +84,13 @@ public class LeaderTragicEventTest extends SolrCloudTestCase {
 
       waitForState("Timeout waiting for new replica become leader", collection, (liveNodes, collectionState) -> {
         Slice slice = collectionState.getSlice("shard1");
-
+        log.info("Waiting for leader: numReps={} oldLeaderName={} currentLeader={}",
+                 slice.getReplicas().size(), oldLeader.getName(), slice.getLeader());
         if (slice.getReplicas().size() != 2) return false;
         if (slice.getLeader() == null) return false;
         if (slice.getLeader().getName().equals(oldLeader.getName())) return false;
 
+        log.info("New leader found: {}", slice.getLeader().getName());
         return true;
       });
       ClusterStateUtil.waitForAllActiveAndLiveReplicas(cluster.getSolrClient().getZkStateReader(), collection, 120000);