huangdongfa closed pull request #1899: Fix error nodesUninitialized count when 
checkCovered
URL: https://github.com/apache/bookkeeper/pull/1899
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RoundRobinDistributionSchedule.java
 
b/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RoundRobinDistributionSchedule.java
index d07940823b..a6506afe72 100644
--- 
a/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RoundRobinDistributionSchedule.java
+++ 
b/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RoundRobinDistributionSchedule.java
@@ -380,8 +380,9 @@ public synchronized boolean checkCovered() {
                     } else if (covered[nodeIndex] != 
BKException.Code.NoSuchEntryException
                             && covered[nodeIndex] != 
BKException.Code.NoSuchLedgerExistsException) {
                         nodesNotCovered++;
-                    } else if (covered[nodeIndex] == 
BKException.Code.UNINITIALIZED) {
-                        nodesUninitialized++;
+                        if (covered[nodeIndex] == 
BKException.Code.UNINITIALIZED) {
+                            nodesUninitialized++;
+                        }
                     }
                 }
                 // if we haven't seen any OK responses and there are still 
nodes not heard from,


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to