FabricFabricHarness
EcosystemDatabases

Databricks Lakebase

Durable state for Databricks Apps using exchanged database credentials.

Lakebase is Fabric's preferred durable Postgres path inside Databricks Apps. Configure the database connection fields and the full endpoint resource name:

DATABRICKS_LAKEBASE_HOST=ep-id.database.us-west-2.cloud.databricks.com
DATABRICKS_LAKEBASE_DATABASE=databricks_postgres
DATABRICKS_LAKEBASE_USER=00000000-0000-0000-0000-000000000000
DATABRICKS_LAKEBASE_ENDPOINT=projects/<project>/branches/<branch>/endpoints/<endpoint>
PGPORT=5432

databricksApp() also accepts PGHOST, PGDATABASE, PGUSER, PGPORT, and ENDPOINT_NAME, which align with App database resource configuration. The Databricks bundle exchanges the app's workspace OAuth identity for a short-lived database credential, refreshes it with single-flight protection, and injects Lakebase-backed session, submission, and conversation-stream stores into the shared server. A raw workspace token is rejected as a database password.

Use lakebaseClient() when assembling a custom bundle. For the standard path, follow Databricks App deployment, including the live restart and credential-exchange smoke. Local contract tests cannot validate workspace permissions or the hosted credential response shape.