Skip to main content

Module codec

Module codec 

Source
Expand description

Encoding/decoding of messages in pgwire. See “Frontend/Backend Protocol: Message Formats” in the PostgreSQL reference for the specification.

See the crate docs for higher level concerns.

Structs§

Cursor
Decodes data within pgwire messages.

Enums§

CodecError
DecodeState

Constants§

ACCEPT_SSL_ENCRYPTION
FORWARDED_STARTUP_PARAM_ALLOWANCE
Startup budget allowed on top of MAX_STARTUP_FRAME_SIZE for parameters a balancer appends while forwarding.
MAX_FORWARDED_STARTUP_FRAME_SIZE
Maximum size of a startup frame accepted from a client that may be behind a balancer.
MAX_PREAUTH_FRAME_SIZE
Maximum frame size accepted from a client that has not yet authenticated.
MAX_REQUEST_SIZE
Maximum allowed size for a request.
MAX_STARTUP_FRAME_SIZE
Maximum size of a startup frame accepted directly from a client.
REJECT_ENCRYPTION

Traits§

Pgbuf

Functions§

decode_startup
Reads and decodes one startup message from the client.
input_err
Constructs an error indicating that the client has violated the pgwire protocol.
parse_frame_len
Parses a frame length header, rejecting frames larger than max_frame_len.