Skip to main content
Version: Next

Installation & Deployment

One QueryFlux server sits between your clients and your engines. Everything around it — Studio, Postgres, identity, policy, metrics — is optional until you need it. To try QueryFlux in a few minutes, start with a Quickstart.

Reference architecture​

Reference architecture: clients send SQL to QueryFlux; QueryFlux routes, queues, and translates, then dispatches to query engines; Postgres holds config, history, and capacity; optional Studio, Prometheus, OIDC or LDAP, and OPA or Cerbos plug in around the server

Components​

ComponentPurposeRequired?Options
QueryFlux serverAccepts client protocols, routes each query to a cluster group, enforces concurrency limits, translates SQL, and dispatches to an engine. One Rust binary.YesBinary · Docker · Helm
Python + sqlglotDialect translation and pythonScript routers.For translationBundled in the Docker image; queryflux --install-deps for the binary
Admin APIHealth, readiness, /metrics, and the API behind Studio. Runs inside the server on port 9000.Yes—
QueryFlux StudioWeb UI for clusters, routing, query history, and access control.NoSeparate image (queryflux-studio); Compose service or Helm sidecar
PostgresPersistence for config, query history, the shared queue, and capacity limits. Required for more than one replica.ProductionAny Postgres; see Multi-replica operations
Query enginesWhere queries actually run.YesTrino, StarRocks, DuckDB (embedded), Athena, ClickHouse, MySQL, ADBC (Snowflake, Databricks, BigQuery, Redshift)
Identity providerAuthenticates clients.NoStatic users, OIDC, LDAP — see Authentication
Policy engineRow filters, column masks, allow/deny.NoOPA, Cerbos
MetricsScrapes /metrics on the admin port.NoPrometheus + the repo's Grafana dashboards — see Observability

How to deploy QueryFlux​

Local (binary)DockerKubernetes (Helm)
Best forDevelopment, single VMSingle host, Compose stacksProduction
StudioRun separatelySeparate queryflux-studio serviceHelm studio sidecar
ReplicasOneOne per container (Postgres for more)Many, with Postgres
Autoscaling / PDB / ingress——Built into the chart

Ports​

Every install method uses the same default ports. Only the frontends you enable in config.yaml listen.

PortWhatNotes
8080Trino HTTP frontendTrino CLI, JDBC, Python clients
5432PostgreSQL wire frontendpsql, Postgres drivers
3306MySQL wire frontendmysql, BI tools
9000Admin API/health, /readyz, /metrics, Studio backend
3000QueryFlux StudioSeparate queryflux-studio image / Helm sidecar

Snowflake HTTP, Arrow Flight SQL, and MCP ports are set per frontend; see the YAML reference.

Persistence: pick before you go to production​

persistence.typeUse forReplicas
inMemoryLocal tryouts, single instanceOne only. Queues, history, and config live in the process.
postgresProductionMany. Config, capacity limits, and the queue are shared across replicas.

Scaling out​

  • Multi-replica operations — capacity leases, queue claims, drain, and crash recovery.
  • Worker mode — a control plane plus workers that pull config from it, deployed as a pool, a DaemonSet, or sidecars.
  • ADBC drivers — install drivers for Snowflake, Databricks, BigQuery, and Redshift backends.

After installing​

  1. Configure clusters, cluster groups, and routers.
  2. Set up authentication — static users, OIDC, or LDAP.
  3. Open Studio to watch query history and edit routing.