Skip to main content

encode_rowset

Function encode_rowset 

Source
pub fn encode_rowset(rows: &[MaybeRow]) -> Result<Bytes, WireError>
Expand description

Encodes a rowset into the wire format.

Fails rather than emitting a rowset the server will reject or, worse, misread: every limit is checked before allocating the output buffer. This matters because Bytes may share its backing storage: many values can name one 16 MiB buffer, while their encoded rowset would require far more memory. The Go writer validates the same three per-row limits before producing a byte; the attachment limit is this client’s additional bound.