PipelineEventBookkeepingRouter
The stdio and socket input channel differ in subtle and critical ways
record-wise, sockets are cold flows, stdio publishes to a partitioned channel
sockets receive checkpointId on the record, stdio infers from state message order
speed will receive complete/incomplete on all sockets (no need to publish)
because they are flows, sockets don't need memory management; the buffer can serve as the
backpressure scheme (note: the exception to this is for file transfer, which forwards the
record after handling the file; and of course obviously for state)These differences might diverge/converge as we tune (i.e., because of lock contention with multiple sockets, or because the socket pattern ends up working for stdio as well). For now, since the main difference is what is done with the pipeline events, we'll consolidate bookkeeping into a single class that yields events from DestinationMessage(s). CheckpointIds can be inferred if the record does not provide one.