Skip to main content

Module codec

Module codec 

Source
Expand description

Arrow IPC framing for PyroLink QUIC streams.

Each message on a bidirectional QUIC stream is encoded as:

┌────────┬──────────┬──────────────────────────────────────┐
│ type 1B│ len 4B LE│ Arrow IPC message (Flight payload)   │
└────────┴──────────┴──────────────────────────────────────┘

For streaming responses (e.g. DoGet), the server sends multiple framed messages followed by a single [MsgType::Eos] byte with no length field.

All multi-byte integers are little-endian.

Enums§

RpcType
The RPC operation encoded in the first byte of a new QUIC stream.

Constants§

MSG_DO_ACTION
Wire type byte for a DoAction request.
MSG_DO_GET
Wire type byte for a DoGet request.
MSG_DO_PUT
Wire type byte for a DoPut request.
MSG_EOS
Wire type byte marking end-of-stream (no length or payload follows).
MSG_GET_FLIGHT_INFO
Wire type byte for a GetFlightInfo request.
MSG_LIST_ACTIONS
Wire type byte for a ListActions request.
MSG_NOTIFICATION
Wire type byte for a server-pushed notification (LISTEN/NOTIFY, WATCH).
MSG_PREPARE_STATEMENT
Wire type byte for a PrepareStatement request.
MSG_QUERY
Wire type byte for a direct SQL query (single-roundtrip: SQL in, results out).
MSG_RECORD_BATCH
Wire type byte for an Arrow RecordBatch message.
MSG_SCHEMA
Wire type byte for an Arrow Schema message.
MSG_TOPOLOGY
Wire type byte for a topology request (adaptive transport negotiation).

Functions§

read_message
Read one framed message from the stream.
read_rpc_type
Read the RPC type byte from the start of a new QUIC stream.
write_eos
Write the EOS marker (0xFF) to the stream and finish it.
write_message
Write one framed message to the stream.