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

Function RunMessageLoop

server/exports.go:277–283  ·  view source on GitHub ↗

RunMessageLoop runs the main message loop for a client connection. It cancels the connection context when the loop exits, ensuring in-flight query contexts (and any gRPC calls derived from them) are cancelled promptly.

(cc *clientConn)

Source from the content-addressed store, hash-verified

275// after the activator installs the executor. A failure there fails the
276// activation, which is connection-fatal, matching the eager path's refusal.
277//
278// Do NOT reach for ApplyConnectionS3CacheOption from inside an activator: at
279// that point the executor is still nil, the worker swap silently no-ops, and
280// the session flag flips anyway.
281func SetPendingS3CacheOption(cc *clientConn, raw string) {
282 if cc != nil {
283 cc.pendingS3Cache = raw
284 cc.hasPendingS3Cache = true
285 }
286}

Callers 1

handleConnectionMethod · 0.92

Calls 4

registerConnMethod · 0.80
unregisterConnMethod · 0.80
messageLoopMethod · 0.80

Tested by

no test coverage detected