remove() renamed to rmrf()

Change-Id: I9166fea623694ae01cca9dc4ad07a29cb9e0c480
Reviewed-on: http://review.couchbase.org/31543
Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
Tested-by: Trond Norbye <trond.norbye@gmail.com>
Move stream class to its own source/header file

The stream class will eventually be a state machine that will
manage all mutations sent over a particular stream. Since there
will be a decent amount of code for a stream we should add a
source and header file for the Stream class.

Change-Id: I9d865fd8f0129dd216bb843c23128289b79d3f99
Reviewed-on: http://review.couchbase.org/31458
Reviewed-by: David Liao <david.liao@couchbase.com>
Tested-by: David Liao <david.liao@couchbase.com>
Make sure seqno's are in the right order upon checkpoint creation

When we are assigning sequence numbers we need to make sure that
if a checkpoint start message is added to the checkpoint manager
then we need to also make sure that we assign a sequence number
to the checkpoint start message before the mutation.

Change-Id: I9529d6866573e4fcf47d419bd71c3a32d75f4bf3
Reviewed-on: http://review.couchbase.org/31462
Reviewed-by: David Liao <david.liao@couchbase.com>
Tested-by: David Liao <david.liao@couchbase.com>
Add an ActiveStream class

The ActiveStream class will maintain the state for a stream that
is on the producer side of the connection. I wil add a similar
PassiveStream for consumer-side stream state in the future.

Change-Id: If884c335131da9f9138e63a2dda15d28fdc9a3b5
Allow the checkpoint manager to work with upr streams

This is a large change that does a few things other than just
allowing a stream to access the checkpoint manager. The main
feature of this change is that the Stream class is now a state
machine that contains states for pending, backfilling, in-memory,
and dead and the stream moves through these states based on how
far behind or up to date the mutations being sent from the stream
are. The Stream class also becomes the main place for handling
mutations in an UPR connection.

Change-Id: I4f5d6a49e31e992bd34b2bce5d8089ccbaffb1f4
Remove backfill callbacks from the ConnMap class

UPR will have it's own seperate backfilling code so we no longer
need to use the callbacks that Tap conenctions use when they do
backfill. Having our own UPR backfilling logic should also lower
lock contention since we will lock based on the Stream as opposed
to the Connection.

Change-Id: I6786b0f1397d94b6ed126a7b62afb30eaceae53a
Don't assign checkpoint start/end/dummy items a by sequence number

Change-Id: Ib374ccda99179b93c80bdd8d36cdfb4bf0caaf4e
Add takeover stream logic

Change-Id: Ia7925442b9f8cb984639b331ae642d90c9ef94a0