In-process link between two Raxol.Agent.Tunnel endpoints.
Wires each endpoint's outbound send_fun to deliver frames into the other's
mailbox as {:tunnel_recv, binary}. This is a real, deterministic transport
(no network) for tests and same-node co-driving: the full open/data/close
multiplex runs through the actual Frame encode/decode path.
A cross-machine transport (Mint.WebSocket on the host dialling out to a
Bandit/Cowboy endpoint on the server) is the production adapter: it does the
same two things this helper does -- set each endpoint's send_fun to write the
socket, and forward inbound socket bytes as {:tunnel_recv, bytes}.
Summary
Functions
Connect two endpoints so frames flow both ways in-process.
Functions
@spec connect(Raxol.Agent.Tunnel.server(), Raxol.Agent.Tunnel.server()) :: :ok
Connect two endpoints so frames flow both ways in-process.
Accepts pids or registered names. The host endpoint sends its hello frame when its link is attached.