projector rollback and generic Feed, endpoint.

adminport:

- Removed RequestStat() API. It is upto the hosting application to gather
  statistics (including its adminport) and send back relevant response.
- graceful shutdown of admin-port server based on ConnState callback.

projector:

- Feed, BucketFeed and KVFeed are collapsed into single gen-server for control
  path.
  - There is also a back-channel to Feed from datapath to communicate ROLLBACK
    and other response status.
- refactored adminport.go and projector.go with simpler and richer set of
  APIs, this is mostly based on the indexer use cases.
- projector client is now available for coordinator and indexer which provides
  a natural set of APIs that directly map to adminport requests.
- implemented upr-rollback handling.
  - UPR can response with ROLLBACK for StreamRequest, this needs to be
    captured and communicated back.
- API calls to start, restart, shutdown vbucket streams wait for corresponding
  response from UPR and only then returns back to the caller.
  This implies that downstream components like indexer / coordinator might
  start receiving mutations, before request to projector has returned.
- RouterEndpoints are generic, while creating a Feed, application must supply
  a RouterEndpointFactory function that will be used by Feed to instantiate
  RouterEndpoints.
  - RouterEndpoints must implement Endpoint{} interface.
- Improvised Evaluator{} and Router{} interface so the projector can be
  entirely agnostic about partitions, topology and endpoints.
- moved to DP4 query.

protobuf:

- Makefile fixed to rewrite import for goprotobuf.
- streamlined (simplified) request messages for projector's adminport.
- Evaluator{} and Router{} interface is implemented by IndexInst{}
  structure. Constructing an instance based on IndexInst{} structure will
  automatically fit in with projector's evaluation and routing algorithm.

dataport:

- endpoints are specific to downstream components, hence moved endpoint
  client to dataport package and refactored as DataportEndpoint.
  - corresponding factory function is also provided.
- data structures defined under common/mutation.go are specific to dataport,
  hence renamed them to include DataPort prefix.

misc:

- debug.go includes a helper function dump stack-trace at ERROR level.

patchset-3:
- upgraded to latest gomemcached changes (merging UprOpcode to CommandCode).
- golint changes
- fixed tools/*
- partition key expression is optional

patchset-4:
- StreamBegin is pushed downstream with start-sequence number,
  this is applicable for starting a new feed, add streams for a bucket,
  restarting streams for existing buckets.
- `bucketname` field in VbKeyVersions is mandatory.

patchset-5:
- reverting kv_sender.go and meta_repo.go to `origin:master` version.

patchset-6:
- CBIDXT-66: consolidating dataport behaviour to ConnectionError.
- CBIDXT-221: collapse mutation-channel and side-band channel in dataport.

patchset-8:
- CBIDXT-231: WHERE clause can be specified in CREATE INDEX DDL to skip
  documents that does not evaluate to true. On the projector, this
  means -
  * If WHERE clause predicate is empty, always proceed evaluating for
    secondary-keys like described earlier.
  * Else,
    * If predicate is true, proceed evaluating for secondary-keys
      like described earlier.
    * Else, skip document and broadcast UpsertDeletion for docid.

patchset-9:
- CBIDXT-100: Handle UPR_EXPIRATION message.
  Handled in the same way as UPR_DELETION.

patchset-10:
- CBIDXT-51: flow control between router and downstream endpoint.

patchset-11:
- use FailsafeOpAsync(), instead of FailsafeOp(), for asynchronous call
  to gen-server.

patchset-12:
- CBIDXT-236: StackTrace() for panics.

patchset-13:
- Implemented John's comment.
  * protect adminport_httpd:Start() with mutex.

Change-Id: I37b483fc7d8cdc83ff1658e4c321c4b8f6c3b193
Reviewed-on: http://review.couchbase.org/41896
Reviewed-by: John Liang <johliang00@gmail.com>
Reviewed-by: Pratap Chakravarthy <prataprc@couchbase.com>
Tested-by: Pratap Chakravarthy <prataprc@couchbase.com>