ivankelly commented on a change in pull request #657: DistributionSchedule uses 
int[] rather than HashSet
URL: https://github.com/apache/bookkeeper/pull/657#discussion_r147636628
 
 

 ##########
 File path: 
bookkeeper-server/src/main/java/org/apache/bookkeeper/client/PendingReadOp.java
 ##########
 @@ -323,7 +327,12 @@ private synchronized int getNextReplicaIndexToReadFrom() {
         }
 
         private int getReplicaIndex(int bookieIndex) {
-            return writeSet.indexOf(bookieIndex);
+            for (int i = 0; i < writeSet.size(); i++) {
 
 Review comment:
   writeSet already has indexOf. Removing the whole method.

----------------------------------------------------------------
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