Add shutdown() to stop the connection

Change-Id: I640d31a0bfdd2d44460b1b25eba37b766c89c2b6
Reviewed-on: http://review.couchbase.org/24215
Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
Tested-by: Trond Norbye <trond.norbye@gmail.com>