Chuyển tới nội dung chính

Query engines

Control Plane → Infrastructure → Engines is the registry of the query engines of the platform: the Trino and StarRocks clusters that run SQL for SQL Lab, charts and dashboards. An engine here is either provisioned by egret, or external: a cluster you run yourself and have registered so egret can manage its access policy.

The Engines list with the Trino and StarRocks tabs: the provisioned docs-trino and the external docs-trino-ext and trino-demo-ext

You need engine:read to open the page. Registering and creating engines need engine:create.

The engine list​

A summary strip counts engines, how many are running and not running, and how many are external. Tabs filter by engine type: Trino and StarRocks, the types egret provisions. Another type gets a tab only when the registry holds an engine of that type, so every engine is listed under a tab. Search Trino engines… filters the list by name.

ColumnMeaning
NameThe engine name. It links to the engine page.
Typetrino or starrocks.
EndpointThe host:port a workspace connection to the engine dials: for example docs-trino-trino.egret-engines.svc:8443 for a provisioned Trino engine with JWT delegation, the host and port you entered (for example trino-demo:8080) for an external one.
StatusThe lifecycle status of a provisioned engine (Provisioning, Running, Failed). External for a registered one: egret does not monitor it.
ActionsDetails opens the engine.

A provisioned Trino engine can also carry a Re-apply needed badge (the API field is securityReapplyNeeded on the engine). Its tooltip says This engine still accepts unauthenticated requests on port 8080. Re-apply it to turn on authentication. The engine was applied before platform #842 and still runs the old configuration. The badge clears after the next successful apply. An engine with JWT only and no password users never shows it. See Provision an engine.

Since platform #847 a StarRocks engine can carry two more badges beside the status:

  • Security upgrade needed for a provisioned engine on an image or login that lacks egret's security fixes. Open the engine and press Upgrade security (see Engine detail).
  • Not governed for a StarRocks engine with no policy profile while Ranger is on (see Engine detail).

The Engines list with the Security upgrade needed and Not governed badges on StarRocks engines

Add an engine​

Two buttons sit at the top right:

ButtonDoes
Register external engineRecords a cluster you run yourself. Egret does not provision, restart or monitor it. See Register an external engine.
Add engineStarts a Trino or StarRocks cluster against catalogs from the registry. See Provision an engine.

Where a provisioned engine runs depends on how egret is deployed. On Kubernetes egret creates Deployments and Services in the engine namespace. With the Docker provisioner ([engines] provisioner = "docker"), egret starts each engine as Docker containers on the same Docker host.

Demo stack

The Docker demo stack uses the Docker provisioner: Add engine starts Trino as containers named egret-engine-egret-engines-<name>-coordinator (and …-worker-<i>). The first engine pulls the trinodb/trino image; plan about 1.5 to 2 GB of memory per engine. StarRocks engines, ingress, pod logs and the shell are Kubernetes-only (see Engine detail). After just demo-down and just demo-up the engine containers are gone: press Restart on each engine to create them again.

Which one to choose​

Provisioned engineExternal engine
Who runs the clusterEgret, on Kubernetes or DockerYou
Lifecycle, monitoring, restartEgretYou
Policy profileCreated and bound automaticallyYou create it and bind it (see Engines and policy)
Ranger pluginConfigured by egretYou install it from the Plugin config tab
Assign to workspacesYes, when JWT authentication is onNo: the workspace picker lists provisioned engines only
DeleteDestroys the cluster (pods or containers)Removes the record only

Open an engine​

Select the name or Details on a row. The page depends on the kind: see Engine detail.

How engines relate to catalogs and workspaces​

  • A catalog (see Catalogs) becomes queryable on an engine when it is attached (provisioned engine) or declared (external engine).
  • A workspace sees the engines assigned to it, plus the database connections an admin adds in Workspace settings → Connections (see Connections).
  • Governance policies reach an engine through the profile the engine downloads (see Engines and policy).

Limits and known issues​

  • Egret cannot see whether an external engine is up or whether it downloads its profile.
  • After a delete the list can keep showing the engine until you reload the page.

Further reading​