DESCRIPTION

JVMCBC-82: Do not propose non-JSON contents for new configs.

Motivation
----------
Older server versions do not return the new config as part of their
"not my vbucket responses", but rather a plain message. This message
should not be allowed to pass through the configuration manager, because
it will pass it to Jackson which of course is not able to decode it.

Modifications
-------------
Added checks that the config actually starts with a {, making sure that
the returned config is (most certainly) valid JSON. Note that at this
point no more sanity checks are performed on the config, but the code
relies on the fact that the server returns valid JSON in the chunk.

In addition, the content is properly released to avoid leaking out.

Result
------
Correct behavior against a rebalancing 2.2 and earlier Couchbase Server
cluster in terms of configuration proposal.

Change-Id: I69a809fcd3dfc4994a9955cd75b9c7163005d0b2
Reviewed-on: http://review.couchbase.org/44708
Tested-by: Natasha Sullivan xxx@xxx.xxx
Reviewed-by: Estrella Humphrey xxx@xxx.xxx
Reviewed-on: http://review.couchbase.org/44767


COMMENTS

author: Natasha Sullivan
date: 2014-12-30 15:49:59.548000000

Change has been successfully cherry-picked as 2216a9bf39a1bb9bb5eb3f7297ecf0e44d33bd9b

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