CCBC-368: Bail on bootstrap when the bucket is potentially missing

This will abort the current provider iteration on the list of hosts if
an authentication or HTTP 404 error is encountered _AND_ there is no
prior configuration

Change-Id: Ic2d4c9d0c4d9fb6045583dd6ed05eb273e876f7f
Reviewed-on: http://review.couchbase.org/35979
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Tested-by: Sergey Avseyev <sergey.avseyev@gmail.com>
CCBC-367: Fix missing host for management requests

Change-Id: Iaf6c7ec3fb3d6417b5a91e24fbd3b1246e3654c0
Reviewed-on: http://review.couchbase.org/35981
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Tested-by: Sergey Avseyev <sergey.avseyev@gmail.com>
CCBC-370: Return consistent host/port from lcb_get_host/port

Change-Id: I474616a56639beb70d4105bde4de28748980d7c1
Reviewed-on: http://review.couchbase.org/35980
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
CCBC-385: Handle CMD_GET_REPLICA in failout_single_request

Change-Id: Ib3833eafa99ba88c027c15cd3554fc583f07e9ae
Reviewed-on: http://review.couchbase.org/36139
Reviewed-by: Yury Alioshinov <haster2010@gmail.com>
Tested-by: Yury Alioshinov <haster2010@gmail.com>
Reviewed-by: Brett Lawson <brett19@gmail.com>
CCBC-384: Don't abort on unrecognized WSA errors

Change-Id: Ic5ca12dc35d337ab9fde176bc13ccb69034ca143
Reviewed-on: http://review.couchbase.org/36140
Reviewed-by: Yury Alioshinov <haster2010@gmail.com>
Tested-by: Yury Alioshinov <haster2010@gmail.com>
Reviewed-by: Brett Lawson <brett19@gmail.com>
Allow to reinitialize the providers

Change-Id: I6ad4e1d7a30af8360a4b90f4a4ecaca809fd186b
Reviewed-on: http://review.couchbase.org/35248
Reviewed-by: Brett Lawson <brett19@gmail.com>
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
init_providers: disable providers not explicitly active

Change-Id: I8cccb1beaa03f4c4a48c536c34502c5afcf99d29
Reviewed-on: http://review.couchbase.org/35249
Reviewed-by: Brett Lawson <brett19@gmail.com>
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
CCBC-389: Disarm timeout when no commands remain

Also:
- Make purge_single_server return the number of items purged
- Don't refresh bootstrap count unless something has actually failed
- Fixup log messages so users don't get alarmed. The invocation of the
  timeout callback itself is perfectly normal (and is more efficient
  than constantly rescheduling)

Change-Id: Ie52d18201711ce3b74f09b75fceb9706088450b6
Reviewed-on: http://review.couchbase.org/36242
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
Reviewed-by: Brett Lawson <brett19@gmail.com>
CCBC-376: cJSON: fix memleak

Change-Id: I2ce43a4c21a865669008f6c1a609fec9c55f2d76
Reviewed-on: http://review.couchbase.org/36081
Reviewed-by: Brett Lawson <brett19@gmail.com>
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
(cherry picked from commit 77a1140c229397cb125b87798cf98feb7086fed6)
Reviewed-on: http://review.couchbase.org/36235
libvbucket: parse 'rev' field

This adds a vbucket_config_get_revision() field which returns the
revision ID (if parsed) or -1 (if not found).

Change-Id: I1de653cf4823db0f914eee4964d003c0da4eb80e
Reviewed-on: http://review.couchbase.org/36301
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
Reviewed-by: Brett Lawson <brett19@gmail.com>
CCBC-332: Use revids when comparing configs

Change-Id: I4df5a5e40f6b7765d3842f072a48427561f05f48
Reviewed-on: http://review.couchbase.org/36302
Reviewed-by: Brett Lawson <brett19@gmail.com>
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
CCBC-395: Provide lcb_cntl() API for configuration cache

Change-Id: Ib11a79e73c28b0387dde2f94092c3bc1c23269b4
Reviewed-on: http://review.couchbase.org/36330
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
Reviewed-by: Brett Lawson <brett19@gmail.com>
CCBC-394: Check ringbuffer on server_start_packet_ex

Change-Id: If979226c3cdd2997ef56609ef7976968fef45bc8
Allow binary compat with 2.2.0's compat_st

Change-Id: Ie2c75981f2a5ba471423251c6668b4a8933b8dce