code: function(options, result) {
        if (this.cb) this.shutdown();
        var cnx = {
          host: options.host,
          bucket: options.bucket ? options.bucket : options.database
        };
        var builder = cb.Connection;
        var self = this;
        this.mock = false;
        if (options.params.mock) {
          builder = cb.Mock.Connection;
          this.mock = true;
        }
        this.cb = new builder(cnx, function(err) {
          if (err) {
            result.reject(err);
            manager.emit('error', err);
            self.shutdown();
          } else {
            result.resolve(manager, self);
            manager.emit('connect', manager, self);
          }
        });
        if (this.mock) {
          result.resolve(manager, self);
          manager.emit('connect', manager, self);
        }
        return result;
      }
docs: Connects *