DESCRIPTION

JVMCBC-44 : test that if bucket was closed, operations fail fast

Motivation
-----------
When calling close() on a Bucket, one expects not to be able to use the bucket
operations anymore. This was not previously the case (would results in a
TimeoutException from the underlying AsyncBucket after a delay).
Now the core fails the operation with a BucketClosedException.

Modifications
-------------
Added integration tests to check behavior of Bucket once closed. Test both
async and sync cases.

Note that with the core modification, users can be impacted if they were
watching for TimeoutExceptions specifically to detect a closed bucket.

Also did a quick fix on ClusterDependentTest to create test bucket with the
correct password expected later.

Result
------
The following behaviors are expected and tested for :
Blocking operations on a closed bucket immediately throw a BucketClosedException.
Async operation call the subscriber's onError method with BucketClosedException.

Change-Id: I33f49052a515b06b8ebee7cadab31c6e1acd8209
Reviewed-on: http://review.couchbase.org/42203
Tested-by: Estrella Humphrey xxx@xxx.xxx
Reviewed-by: Cory Peck xxx@xxx.xxx
Reviewed-by: Natasha Sullivan xxx@xxx.xxx


COMMENTS

author: Cory Peck
date: 2014-10-17 15:18:55.605000000

Change has been successfully cherry-picked as b0921cef15e527e3b7bb5d4d35bde21575b1a3b4

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