Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PostHog/duckgres
/ functions
Functions
5,901 in github.com/PostHog/duckgres
⨍
Functions
5,901
◇
Types & classes
803
↓ 8 callers
Method
RetireFromSnapshot
RetireFromSnapshot moves the observed worker row to a terminal state (retired or lost) fenced by the snapshot. Used by paths that already own the work
controlplane/worker_lifecycle.go:86
↓ 8 callers
Function
categoryLabel
(category: ErrorCategory)
controlplane/admin/ui/src/lib/errors.ts:29
↓ 8 callers
Method
deleteWorkerRPCSecret
(ctx context.Context, podName string)
controlplane/worker_rpc_security.go:175
↓ 8 callers
Function
doPost
(t *testing.T, r *gin.Engine, path string)
controlplane/admin/kill_switch_test.go:23
↓ 8 callers
Function
ducklingCRName
ducklingCRName returns the Duckling CR name for a warehouse row: the stored duckling_name, which is authoritative (the control plane never derives it)
controlplane/provisioner/controller.go:45
↓ 8 callers
Function
ducklingEntryFor
( entries: Record<string, T> | undefined, orgName: string, ducklingName: string | undefined, )
controlplane/admin/ui/src/lib/format.ts:151
↓ 8 callers
Function
get_conn
(**kwargs)
scripts/client-compat/clients/psycopg/test_psycopg.py:28
↓ 8 callers
Method
handleExecute
(body []byte)
server/conn_extended_query.go:491
↓ 8 callers
Method
handleQuery
(body []byte)
server/conn.go:1194
↓ 8 callers
Function
isIdleLeak
(idle: number)
controlplane/admin/ui/src/lib/fleet.ts:44
↓ 8 callers
Function
jsonFuncCall
jsonFuncCall builds an unqualified function-call node.
transpiler/transform/operators.go:815
↓ 8 callers
Function
lakeDDLPolicy
lakeDDLPolicy mirrors the lake (DuckLake) DDL policy: silent strip/rewrite.
transpiler/transform/ddl_test.go:12
↓ 8 callers
Method
markWorkerRetiredLocked
markWorkerRetiredLocked is the in-memory retire wrapper for paths that bypass the WorkerLifecycle CAS service: it upserts the durable row first, then
controlplane/k8s_pool_lifecycle.go:1351
↓ 8 callers
Function
mustEnv
(t *testing.T, key string)
tests/scenario/runner_test.go:446
↓ 8 callers
Function
mustExecTx
(t *testing.T, tx *sql.Tx, stmt string)
tests/integration/cursor_test.go:88
↓ 8 callers
Function
newTestSnapshot
(t *testing.T, workerID int, state configstore.WorkerState, cpID string, epoch int64)
controlplane/worker_lifecycle_test.go:143
↓ 8 callers
Function
nodePool
(node: any)
controlplane/admin/ui/src/pages/nodes/peepernetes.ts:153
↓ 8 callers
Function
orgLoadPercent
(workers: number, maxWorkers: number)
controlplane/admin/ui/src/lib/fleet.ts:52
↓ 8 callers
Function
post
(path: string, body: unknown)
controlplane/admin/ui/src/lib/api.ts:106
↓ 8 callers
Function
recoverWorkerPanic
recoverWorkerPanic converts a nil-pointer panic from a closed Flight SQL client into an error. Same race as FlightExecutor: arrow-go Close() nils out
controlplane/worker_mgr.go:1255
↓ 8 callers
Method
registerConn
registerConn adds a client connection to the registry for pg_stat_activity.
server/server.go:745
↓ 8 callers
Method
releaseWorkerSocket
releaseWorkerSocket returns a pre-bound socket to the pool for reuse, or closes the listener and removes the socket file for non-pre-bound sockets. Sa
controlplane/worker_mgr.go:287
↓ 8 callers
Function
resolveRunTemplates
(s core.Scenario, runID string)
tests/scenario/runner_test.go:542
↓ 8 callers
Method
sendSignal
(sig syscall.Signal)
tests/controlplane/controlplane_test.go:230
↓ 8 callers
Function
stringFromWith
(step core.Step, key, fallback string)
tests/scenario/dbt/steps.go:353
↓ 8 callers
Method
workerMatchesLease
(w *ManagedWorker, lease workerLeaseSnapshot)
controlplane/k8s_pool_lifecycle.go:1017
↓ 8 callers
Method
workerPodName
(worker *ManagedWorker)
controlplane/k8s_pool_helpers.go:127
↓ 7 callers
Method
Create
(ctx context.Context, username string)
server/flightsqlingress/ingress.go:1528
↓ 7 callers
Method
DoPutCommandStatementUpdate
(ctx context.Context, cmd flightsql.StatementUpdate)
duckdbservice/flight_handler.go:764
↓ 7 callers
Method
Error
()
tests/scenario/core/runner_test.go:326
↓ 7 callers
Method
Exec
(query string, args ...any)
server/sqlcore/interfaces.go:51
↓ 7 callers
Function
GetQuerySchema
GetQuerySchema executes a query with LIMIT 0 to discover the result schema.
duckdbservice/arrow_helpers.go:149
↓ 7 callers
Function
HashPassword
HashPassword hashes a plaintext password using bcrypt.
controlplane/configstore/store.go:573
↓ 7 callers
Function
NewPgCatalogTransformWithConfig
NewPgCatalogTransformWithConfig creates a new PgCatalogTransform with configuration.
transpiler/transform/pgcatalog.go:32
↓ 7 callers
Method
PerSessionThreads
PerSessionThreads returns the thread count for each session. Threads are not subdivided — every session gets the full budget.
controlplane/memory_rebalancer.go:197
↓ 7 callers
Method
QueryContext
(ctx context.Context, query string, args ...any)
duckdbservice/user_secrets.go:18
↓ 7 callers
Function
RequireAdmin
RequireAdmin is a per-route gate for admin-only endpoints (e.g. the audit log read). Unlike RoleGate's path allow-list, it travels with the route regi
controlplane/admin/authz.go:188
↓ 7 callers
Method
Results
()
tests/scenario/core/runner.go:122
↓ 7 callers
Method
RetireOrphanWorker
(record *configstore.WorkerRecord, reason string)
controlplane/worker_lifecycle.go:36
↓ 7 callers
Method
Run
(ctx context.Context)
server/querylog_kafka_writer.go:159
↓ 7 callers
Method
SQLState
()
controlplane/provisioning/api.go:26
↓ 7 callers
Method
Serve
Serve starts serving on the given listener.
duckdbservice/service.go:891
↓ 7 callers
Method
SetDeadline
(time.Time)
server/conn_passthrough_test.go:55
↓ 7 callers
Method
Status
(orgID string)
tests/scenario/provision/steps.go:76
↓ 7 callers
Method
TLSConfig
TLSConfig returns a tls.Config that uses ACME for certificate management. The GetCertificate callback dynamically obtains/renews certificates.
server/tlscert/acme.go:80
↓ 7 callers
Method
Timeout
()
cmd/cache-proxy/proxy_test.go:23
↓ 7 callers
Function
WriteCopyData
writeCopyData sends a row of COPY data
server/wire/protocol.go:392
↓ 7 callers
Function
WriteParseComplete
writeParseComplete sends parse complete
server/wire/protocol.go:311
↓ 7 callers
Function
addIdleWorker
--- Node-age-aware scheduling tests --- These cover the two places the pool uses `nodeFirstSeen`: picking the next idle worker to claim (oldest node
controlplane/k8s_pool_test.go:4468
↓ 7 callers
Function
binExprNode
(op string, l, r *pg_query.Node)
transpiler/transform/functions_compat.go:293
↓ 7 callers
Function
buildCommandTagFromRowCount
buildCommandTagFromRowCount builds a command tag from a command type and row count. Used when results are streamed via Query (e.g., DML RETURNING) rat
server/conn.go:2165
↓ 7 callers
Function
categoryVariant
(category: ErrorCategory)
controlplane/admin/ui/src/lib/errors.ts:15
↓ 7 callers
Method
closeAllCursors
closeAllCursors closes all open cursors on this connection.
server/conn_cursor.go:100
↓ 7 callers
Function
createStrandedWorkerPod
(t *testing.T, cs *fake.Clientset, name, workerIDLabel string, age time.Duration)
controlplane/k8s_pool_test.go:3796
↓ 7 callers
Method
doCopyFromStdin
doCopyFromStdin handles a CSV spool DoPut from the control plane. It writes streamed bytes to a worker-local tempfile, executes the COPY SQL with the
duckdbservice/copy_from_stdin.go:42
↓ 7 callers
Method
ensureMapsLocked
()
server/flightsqlingress/ingress.go:1780
↓ 7 callers
Function
ensureQueryLogTable
(db *sql.DB, tableSchema, tableName, fullTableName string)
server/querylog.go:399
↓ 7 callers
Method
executeSelectQuery
executeSelectQuery runs a result-returning query against DuckDB and streams results to the client. Sends RowDescription, DataRow messages, CommandComp
server/conn_query_exec.go:153
↓ 7 callers
Function
extractIP
extractIP gets the IP address from a net.Addr (strips port).
server/auth/ratelimit.go:63
↓ 7 callers
Function
firstNonEmpty
(a, b string)
controlplane/worker_profile.go:237
↓ 7 callers
Function
fmtMetricAxis
(v: number | null | undefined, unit?: string)
controlplane/admin/ui/src/lib/format.ts:62
↓ 7 callers
Function
formatBytes
formatBytes formats a byte count as a human-readable DuckDB size string. Always uses MB to avoid precision loss from integer division at GB granularit
controlplane/memory_rebalancer.go:240
↓ 7 callers
Function
formatOrderedMapValue
formatOrderedMapValue formats an OrderedMapValue as a key-value text representation, preserving the original insertion order from the Arrow array.
server/conn_results.go:493
↓ 7 callers
Function
formatValue
formatValue converts a value to its PostgreSQL text representation
server/conn_results.go:312
↓ 7 callers
Function
get_url
()
scripts/client-compat/clients/sqlalchemy/test_sqlalchemy.py:38
↓ 7 callers
Function
hashColor
(key: string)
controlplane/admin/ui/src/lib/colors.ts:6
↓ 7 callers
Function
initInformationSchema
initInformationSchema creates the column metadata table and information_schema wrapper views. This enables accurate type information (VARCHAR lengths,
server/catalog.go:1551
↓ 7 callers
Function
killSwitchRouter
killSwitchRouter mounts the live API with the given fakes (no RoleGate — that gating is exercised separately in TestKillSwitchRequiresAdmin).
controlplane/admin/kill_switch_test.go:16
↓ 7 callers
Function
loadArtifacts
(runDir string)
tests/perf/publisher/publisher.go:123
↓ 7 callers
Method
markWorkerRetiredInMemoryLocked
markWorkerRetiredInMemoryLocked performs only the in-memory lifecycle transition for a worker retirement, without persisting to the runtime store and
controlplane/k8s_pool_lifecycle.go:1404
↓ 7 callers
Function
mismatchVersionTestPool
mismatchVersionTestPool builds a pool whose cpID looks like a Deployment pod ("duckgres-<rshash>-<podhash>") so trimK8sPodHashSuffix yields a comparab
controlplane/k8s_pool_test.go:3526
↓ 7 callers
Function
mustHash
(t *testing.T, password string)
controlplane/configstore/store_test.go:10
↓ 7 callers
Function
newAttachStepExecer
(db *sql.DB)
server/attach_timeout.go:82
↓ 7 callers
Function
newTestBroker
(clock *testClock, assume assumeRoleFunc)
controlplane/sts_broker_test.go:33
↓ 7 callers
Method
newTranspiler
newTranspiler creates a transpiler configured for this connection. The backend profile selects DDL/DML/catalog compatibility policy. The client datab
server/conn.go:223
↓ 7 callers
Method
notifySessionCountChanged
(count int)
server/flightsqlingress/ingress.go:1565
↓ 7 callers
Function
observeFlightIngressSessionOutcome
(outcome string)
server/flightsqlingress/metrics.go:32
↓ 7 callers
Method
readWorkerRPCSecurity
(ctx context.Context, podName string)
controlplane/worker_rpc_security.go:158
↓ 7 callers
Method
releaseSem
releaseSem returns the attach semaphore slot acquired by the caller. If any statement was abandoned past its deadline, the release is handed to a goro
server/attach_timeout.go:172
↓ 7 callers
Method
retireWorkerProcess
retireWorkerProcess handles the actual process shutdown and socket cleanup.
controlplane/worker_mgr.go:988
↓ 7 callers
Function
retryOnTransient
retryOnTransient calls fn up to transientMaxRetries additional times when it returns a transient DuckLake error, using exponential backoff.
duckdbservice/transient.go:111
↓ 7 callers
Method
runOnce
()
controlplane/per_cp_hot_idle_reaper.go:71
↓ 7 callers
Method
sendRowDescriptionWithFormats
sendRowDescriptionWithFormats sends a RowDescription message with per-column format codes. formatCodes follow the same convention as Bind result forma
server/conn_results.go:175
↓ 7 callers
Function
sessionCreationErrorResponse
(err error)
controlplane/control.go:744
↓ 7 callers
Method
setQuerySource
setQuerySource records a client-supplied `duckgres.query_source` value on the session. Pass-through: any string is accepted (only "standard"/"endpoint
server/conn.go:271
↓ 7 callers
Method
set_suite
(self, suite: str)
scripts/client-compat/clients/psycopg/test_psycopg.py:61
↓ 7 callers
Function
shutdownTestPool
--- ShutdownAll draining-chain tests --- ShutdownAll is called when the CP pod receives SIGTERM from Kubernetes. The old implementation marked each w
controlplane/k8s_pool_test.go:4186
↓ 7 callers
Function
skipWhitespaceAndComments
skipWhitespaceAndComments advances i past any whitespace, line comments (--), and block comments (/* */) in an uppercased SQL string. Returns the new
server/conn.go:1965
↓ 7 callers
Method
stampActiveOrgLabel
stampActiveOrgLabel patches the worker pod with `duckgres/active-org=<org>`. Strategic-merge so re-activations (e.g. credential refresh) are no-ops on
controlplane/shared_worker_activator.go:225
↓ 7 callers
Function
stringFromWith
(step core.Step, key, fallback string)
tests/scenario/perf/steps.go:343
↓ 7 callers
Function
summarizeFleet
(fleet: FleetStat[] | undefined)
controlplane/admin/ui/src/lib/fleet.ts:28
↓ 7 callers
Method
takePrebound
()
controlplane/worker_mgr.go:251
↓ 7 callers
Function
tokenFingerprint
tokenFingerprint returns a short, non-reversible fingerprint of a session token for safe logging. The x-duckgres-session token is a standalone bearer
server/flightsqlingress/ingress.go:1937
↓ 7 callers
Function
unquoteIdent
unquoteIdent strips double quotes and preserves case, or lowercases unquoted identifiers.
transpiler/show_create.go:211
↓ 7 callers
Function
useIdentity
()
controlplane/admin/ui/src/components/IdentityProvider.tsx:44
↓ 7 callers
Function
writeFake
(t *testing.T, binDir, name, body string)
tests/e2e-mw-dev/run_sh_test.go:235
↓ 6 callers
Method
Catalog
()
transpiler/backend/profile.go:69
↓ 6 callers
Method
CreateSpawningWorkerSlot
(ownerCPInstanceID, orgID, image string, profileCPU, profileMemory string, ownerEpoch int64, podNamePrefix str
controlplane/worker_pool.go:132
↓ 6 callers
Method
DSN
()
tests/scenario/sql/connection.go:22
↓ 6 callers
Method
DoGetStatement
(ctx context.Context, ticket flightsql.StatementQueryTicket)
duckdbservice/flight_handler.go:642
← previous
next →
401–500 of 5,901, ranked by callers