DESCRIPTION

Further hardening of ReplicaRead.

This changeset hardens the implementation of ReplicaRead further
by applying the following changes:

 - Make sure the completedFuture is not overriden by later calls.
 - The "cancel" iterations on the monitoredFutures is synched as
   advised by Collections#synchronizedList.
 - Make sure that replica reads are only "fanned out" to nodes that
   are actually configured as a replica at the moment. For that
   reason, a new method is added to the VBucketNodeLocator to return
   a list of servable nodes for this specific key.
 - Along the lines of the previous point, make sure that an additional
   request to the proper active master is only sent when it is actually
   reachable (not -1 in the vbucket map).

Change-Id: I6568e1c1fd5d779acf3fd1e52ed2d88b46a1a8b7


COMMENTS

author: Andreas Short
date: 2013-11-04 17:23:27.872000000

Patch Set 1: Code-Review+2

(1 comment)

Line:280, src/main/java/com/couchbase/client/vbucket/VBucketNodeLocator.java -> I don't fully understand the comment there.  Are you saying, you're going to recheck because it may have been updated?  I'll read on and maybe figure it out.

-------------------------------------
author: Natasha Sullivan
date: 2013-11-04 17:35:05.551000000

Patch Set 1:

(1 comment)

Line:280, src/main/java/com/couchbase/client/vbucket/VBucketNodeLocator.java -> it is a helper method for up the stack to give you the real list of replica indexes, because just if you have 1 replica defined doesnt mean there is one for this key (because it can be temp disabled during rebalance!)

-------------------------------------
author: Natasha Sullivan
date: 2013-11-04 17:38:43.194000000

Patch Set 1: Verified+1

-------------------------------------
