MCPcopy Create free account
hub / github.com/PostHog/duckgres / pgFrame

Function pgFrame

server/conn_skip_until_sync_test.go:74–79  ·  view source on GitHub ↗

pgFrame builds a framed wire-protocol message: type byte + int32 length (including itself) + body.

(msgType byte, body []byte)

Source from the content-addressed store, hash-verified

72// pgFrame builds a framed wire-protocol message: type byte + int32 length
73// (including itself) + body.
74func pgFrame(msgType byte, body []byte) []byte {
75 frame := make([]byte, 0, 5+len(body))
76 frame = append(frame, msgType)
77 frame = binary.BigEndian.AppendUint32(frame, uint32(4+len(body)))
78 return append(frame, body...)
79}
80
81func parseFrame(stmtName, query string) []byte {
82 var body bytes.Buffer

Callers 9

parseFrameFunction · 0.85
bindFrameFunction · 0.85
describePortalFrameFunction · 0.85
executeFrameFunction · 0.85
queryFrameFunction · 0.85
runPipelineFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected