MB-11104 Skip a checkpoint merge operation based on cursor position

We need to check if there are any cursors in the last closed
checkpoint, which haven't yet visited any regular items belonging
to the last closed checkpoint. If so, then we should skip
collapsing checkpoints until those cursors move to the first
regular item. Otherwise, those cursors will visit old items from
collapsed checkpoints again.

Change-Id: I12ce6509717f692336e849d2da82734d1fa72e16
Reviewed-on: http://review.couchbase.org/37355
Reviewed-by: Michael Wiederhold <mike@couchbase.com>
Tested-by: Chiyoung Seo <chiyoung@couchbase.com>