1655: Bring OuroborosApplication into line with MuxApplication r=karknu a=dcoutts
In a previous patch series we changed the structure of the MuxApplication to simply use a list of mini-protocols, rather than indexing on a mini-protocol enumeration type. That PR kept the OuroborosApplication interface the same however.
This patch finishes that job. Now the OuroborosApplication is also structured as a list of mini-protocols, and there are no more mini-protocol enum types.
This will later allow protocol versioning to be made simpler since now we just have value-level things to deal with, rather than versionnegotiation leading to a separate protocol enum type, requiring existentials etc.
This patch also makes heavier use of the MuxPeer type. The intention is that in future we will not need to have use sites calling runPeer directly, which will make it easier to change the protocol driver. For now however there are various cases where we must use runPeer directly and so we provide MuxPeerRaw as an escape hatch. This provides a direction of travel however.
This builds on top of #1610, so it’s only worth looking at the last 4 patches.