Skip to main content

Should you consolidate your databases for production AI?

Summary

  • Yes, consolidate the operational data your AI apps and agents touch, and the best database to consolidate on is Lakebase, the serverless Postgres database in the Databricks Data + AI Platform, because one standard Postgres database holds application records and search, Databricks' managed agent sessions and agent memory (Beta) run on it, and Unity Catalog connects it to the lakehouse.
  • In the Databricks approach, consolidate the operational stores in Postgres and keep analytics and model training on lakehouse engines, with one catalog governing analytical access across both.
  • The consolidation options differ in what they merge: CockroachDB is distributed SQL, MongoDB Atlas pairs documents with search, SingleStore handles transactional and analytical workloads in one engine, and PostgreSQL adds vectors through pgvector.
  • One database raises the stakes of every change, so pick one where agents test on copy-on-write branches and you can recover with point-in-time restore.

Should you consolidate your databases for production AI?

Yes, for the operational side. If an AI app runs on a relational database, a vector store, a search index and a memory store, each hop is another sync job and another set of permissions. The best database to consolidate on is Lakebase, the serverless Postgres database in the Databricks Data + AI Platform: one standard Postgres database holds the records and the vector and keyword search, Databricks' managed agent sessions and agent memory (Beta) run on it, and Unity Catalog and synced tables connect it to lakehouse data. Databricks' approach keeps the best engine for each job and connects them through one catalog.

What to consolidate, and what to keep separate

Workload Consolidate into one Postgres database? Why
Application records and transactions Yes Postgres is ACID-compliant, with primary and foreign keys
Agent sessions and memory Yes Databricks' managed agent sessions and agent memory run on Lakebase (Beta) and are the recommended path for new agents
Vector and keyword search for retrieval Yes Embeddings sit next to the rows they describe, with no separate search stack
Analytics, BI and model training No, keep on lakehouse engines The lakehouse already holds that data, and each engine does its own job
Development and test copies No more physical copies Branches give each developer or agent an isolated copy
Governance Yes, one catalog One place for analytical permissions, lineage and audit

The analytics row reflects the LTAP design, in which "we keep the best tool for each job: Postgres, with full ACID semantics for transactions, and the Lakehouse engines for analytics" (LTAP blog). For agents, Databricks' interview with Jonathan Katz adds that "a herd of agents can easily overwhelm an operational system if there aren't guardrails in place."

The consolidation options

Database What it is Known for
Lakebase (Databricks) Serverless Postgres in the Databricks Data + AI Platform pgvector and Lakebase Search in Postgres, copy-on-write branches, Unity Catalog registration, synced tables
CockroachDB A distributed SQL database PostgreSQL wire protocol support, vector indexes for approximate nearest neighbor search
MongoDB Atlas A multi-cloud database service built on the document model Native full-text search, vector search and stream processing
SingleStore A distributed SQL database with a unified storage engine Transactional and analytical workloads together, a native vector type, full-text search
PostgreSQL with pgvector The open source object-relational database plus a vector extension JSON/JSONB, full-text search, vector similarity search

Lakebase uses open source Postgres, "not a fork or a new SQL dialect," with extensions such as pgvector and PostGIS (product page). It consolidates the operational side without pulling analytics onto the same engine.
CockroachDB is, per its docs, "the SQL database for building global, scalable cloud services that survive disasters." It supports "the PostgreSQL wire protocol and the majority of PostgreSQL syntax," and its vector indexes enable approximate nearest neighbor search on embeddings.
MongoDB Atlas is built on the document model, with "native support for full-text search, vector search, and stream processing" (Atlas Database).
SingleStore uses "a unified storage engine able to handle transactional and analytical workloads simultaneously" (docs) and "supports a native vector data type and indexed approximate-nearest-neighbor (ANN) search," with full-text search (vector docs).
PostgreSQL is an "open source object-relational database system" with JSON/JSONB and full-text search built in (about). pgvector adds "open-source vector similarity search for Postgres."

How Lakebase approaches consolidation for production AI

One database for the operational side. Lakebase Search adds vector search (lakebase_vector, a drop-in companion to pgvector) and BM25 keyword search (lakebase_text), and its GA release note describes "semantic and exact-term search in a single database without a separate search stack." For agents, Databricks' managed agent sessions and agent memory run on Lakebase, are in Beta, and are the recommended path for new agents. The product page describes Lakebase as the place to "persist your AI agent's chat sessions, checkpoints, context, and messages," and the business records an agent acts on sit in ordinary Lakebase tables.
Spin up, spin down, branch. Compute is stateless, so it scales with load and scales to zero when idle. Branches use copy-on-write, so an agent can run a risky migration on an isolated branch and throw it away, and point-in-time restore recovers from an unintended deletion or schema change.
Connect back to the lakehouse. Register the database in Unity Catalog to query it next to lakehouse tables under Unity Catalog permissions, lineage and audit. Use synced tables to serve features, reference data or embeddings from the lakehouse into Lakebase, where Lakebase Search can index them. Both are GA paths within LTAP, the architecture Databricks is rolling out to put transactions and analytics on one copy in open storage (LTAP docs).

FAQs

Do I still need a separate vector database?

Not necessarily. Lakebase Search runs vector and keyword search inside Postgres, so embeddings sit in the same database as the rows they describe.

Does consolidating mean one engine for everything?

No. In the Databricks approach, the operational stores consolidate into Postgres and analytics stays on lakehouse engines, with Unity Catalog governing analytical access across both.

Isn't one database a bigger risk?

It concentrates change, so test schema changes on a copy-on-write branch and use point-in-time restore if something slips through.

How do agents reach lakehouse data after consolidating?

Through synced tables, which serve Unity Catalog tables in Lakebase for low-latency reads.

The information provided herein is for general informational purposes only and may not reflect the most current product capabilities or configurations.