Process buffered messages before closing a consumer's stream
Process buffered messages before closing a consumer's stream

Attempt to process all buffered messages for a stream to
reduce the amount of data lost, during disconnection or
closing of the specific stream, provided its not a force
shutdown.

Change-Id: I19ad3d10654f1ec33ad92350ece194b46cd56201
Reviewed-on: http://review.couchbase.org/53147
Tested-by: buildbot <80754af91bfb6d1073585b046fe0a474ce868509@couchbase.com>
Reviewed-by: Chiyoung Seo <fcffc23db27b19ee4ebba46695ee6b50e09216a2@couchbase.com>

owendCB/ep-engine,teligent-ru/ep-engine,daverigby/kv_engine,membase/ep-engine,daverigby/ep-engine,couchbase/ep-engine,couchbase/ep-engine,daverigby/kv_engine,daverigby/ep-engine,couchbase/ep-engine,hisundar/ep-engine,teligent-ru/ep-engine,owendCB/ep-engine,hisundar/ep-engine,daverigby/kv_engine,daverigby/ep-engine,teligent-ru/ep-engine,membase/ep-engine,daverigby/ep-engine,hisundar/ep-engine,owendCB/ep-engine,membase/ep-engine,hisundar/ep-engine,membase/ep-engine,daverigby/kv_engine,owendCB/ep-engine,couchbase/ep-engine,teligent-ru/ep-engine