module
CQL::Postgres::Wire::Backend
Overview
Messages a server sends, decoded from their payloads.
Defined in:
postgres/wire/backend.crConstant Summary
-
EAGER_READ_SIZE =
64 * 1024 -
MAX_MESSAGE_SIZE =
1 << 30
Class Method Summary
- .decode(type : Char, reader : Reader) : Message
-
.read(io : IO, max_size : Int32 = MAX_MESSAGE_SIZE) : Message
Reads and decodes the next message from io.
Class Method Detail
Reads and decodes the next message from io. Messages over max_size are refused, and big payloads are buffered only as they arrive so a hostile length cannot reserve memory the peer never sends.