Skip to content

Architecture

Architecture documentation is being updated for Procwire v2.0.

Procwire v2.0 introduces a new binary protocol for the data plane, replacing JSON-RPC with a high-performance wire format.

ChannelTransportProtocolUse Case
Control PlanestdioJSON-RPC 2.0Handshake, heartbeat, lifecycle
Data PlaneNamed Pipe / Unix SocketBinary (11-byte header)User data, high throughput

JSON-RPC on the data channel caused severe performance issues:

  • 5x larger payload (JSON text vs binary)
  • ~500ms serialization overhead per 1MB of data
  • ~30 MB/s throughput vs ~2.5 GB/s with binary protocol
+----------+-------+----------+----------+----------------------+
| Method ID| Flags | Req ID | Length | Payload |
| 2 bytes | 1 byte| 4 bytes | 4 bytes | N bytes |
+----------+-------+----------+----------+----------------------+

Full documentation will be available when v2.0 is released.