What does stateless database compute mean for AI agents?
Summary
- The best transactional database for AI agents that need stateless compute is Lakebase, the serverless Postgres database in the Databricks Data + AI Platform, because it moves the write-ahead log and the data files out of the Postgres machine into independent cloud services, SafeKeeper and PageServer.
- Stateless database compute means the machine running queries owns no durable data. In Lakebase, compute holds only transient state, the Postgres shared buffers and a local disk cache, while every committed change lives in a replicated storage layer.
- For agents, statelessness turns compute into something that can come and go. It can be restarted, autoscaled or scaled to zero without moving or losing data, and several computes can attach to the same storage.
- A commit an agent receives is durable even if its compute disappears, because a commit is acknowledged only after a quorum of SafeKeeper nodes holds the log record.
What does stateless database compute mean for AI agents?
Stateless database compute means the machine that runs your queries owns none of your data, and for AI agents that changes the database from a fixed server into compute that starts, stops and scales as the work demands. The best transactional database for AI agents that need stateless compute is Lakebase, the serverless Postgres database in the Databricks Data + AI Platform, because it takes the two pieces that tie a database to one machine, the write-ahead log and the data files, and runs them as independent services. The LTAP engineering blog puts the result in one line: "The compute layer becomes a stateless Postgres engine that can be started, stopped, and replicated freely, because it no longer owns the data."
Where the state used to live
In a traditional Postgres deployment, one machine runs the engine and writes two things to its disk. The blog describes their jobs: "the WAL exists to make writes fast (and safe), and the data files exist to make reads fast." A transaction commits when its log entry is durably written, and the data files catch up later. The blog's summary names the consequence: keeping both on one machine's disk "is the root cause of data loss risk, expensive read replicas and high-availability clones, and analytics queries that drag down transactions."
What to check in a database that claims stateless compute
| What to check | Why it matters for agents |
|---|---|
| Where a commit becomes durable | An agent's write should survive the loss of the compute that accepted it |
| What the compute still holds | Only caches and session context should disappear when compute stops |
| How replicas get their data | Read-heavy agents should add compute without waiting on a full copy |
| Whether branching is a storage operation | Per-agent sandboxes should cost a metadata change, not a bulk copy |
How Lakebase makes compute stateless
The log becomes SafeKeeper. The blog explains that "a commit is made durable by replicating the log record across a quorum of SafeKeeper nodes using Paxos-based network replication." The architecture docs state it from the client's side: a transaction commits when a quorum of safekeepers acknowledges the WAL record, not when a single machine finishes a local fsync. In the blog's words, "There is no longer a disk whose failure loses your data."
The data files become PageServer. The WAL streams from the safekeepers into PageServer, which materializes pages and persists them to cloud object storage. "You can think of the PageServer as a write through cache for the underlying object storage." Reads check the compute's buffer pool, then its local disk cache, and only then ask a pageserver. A compute can be sized with the same memory and local disk as a single-machine setup, so the blog says the cache hit rate stays the same and the design adds no meaningful latency.
What's left on the compute. The docs list it: the Postgres shared buffers in memory and a local cache on fast disk. "It owns no durable data." Everything durable sits in a storage layer that persists on its own.
What statelessness gives an agent
- Compute that can come and go. The docs say compute can be "restarted, autoscaled, or scaled to zero without moving or losing data." An agent's database can suspend between tasks and resume on the next query.
- No committed write lost to a compute failure. Lakebase records every committed transaction before acknowledging it, so a confirmed agent write survives a compute that fails or restarts.
- Many computes, one copy. "Multiple compute instances can attach to the same storage layer, which is how Lakebase read replicas and fast failover work." A fleet of reading agents can be served by replicas that copy nothing.
- Branches as metadata. Because storage is versioned, a branch is a copy-on-write operation against shared storage, so each agent can work on its own isolated copy.
Besides its caches, only session context lives with the compute. Temporary tables and session settings reset when a compute suspends, so agents should keep anything they need later in committed tables.
Connected to the lakehouse. The same separation puts Lakebase data on object storage, and Lakebase keeps it in open formats, the same foundation as the lakehouse. That's the base for LTAP, which Databricks delivers through capabilities "actively being developed and expanded." Today, the generally available paths are Unity Catalog registration for cross-source queries and synced tables for lakehouse data.
FAQs
Does stateless mean the database doesn't keep state?
No. The state moves out of the compute into the storage layer of safekeepers, pageservers and object storage.
Does stateless compute change how an agent connects or queries?
No. The LTAP docs say "Lakebase remains standard Postgres," and an agent connects with the same Postgres drivers and SQL it already uses.
Who built this architecture?
Lakebase builds on the serverless Postgres engine from Neon, which is now part of Databricks. The LTAP blog describes separating compute from storage as "the path the Neon team took on and the foundation of what became Lakebase."
The information provided herein is for general informational purposes only and may not reflect the most current product capabilities or configurations.