Scrivio Interview library
DesignPrincipal7 min read · updated 12 November 2026

Cloud databases such as Amazon Aurora and Neon separate compute from storage: the log is shipped to a distributed storage layer and pages are rebuilt there, so traditional checkpoints and local fsync work differently. As the person setting the database strategy for your company, how do you evaluate such architectures against classic PostgreSQL on your own volumes?

In these architectures the compute node does not write data pages to its own disk; it sends WAL to a replicated storage service that applies it to pages, so durability comes from quorum writes across zones and replicas share the same storage. That gives fast failover and replica creation, storage that grows automatically, less checkpoint and full-page-write overhead and managed backups, in exchange for per-I/O or storage pricing, provider lock-in, compatibility limits and less tuning control. I would evaluate with our real workload, commit latency, replica lag, failover time and three-to-five-year total cost against self-managed and standard managed PostgreSQL, and keep an exit path through the standard protocol, logical replication and dumps.

Background to this question

Database strategy decisions last for a decade, and compute-storage separation is the most significant architectural change in relational databases in years. Vendors present it as strictly better; sceptics see lock-in. A strategy owner must explain what really changes, then decide with measurements and costs. In this answer, we will recap how classic PostgreSQL achieves durability, explain the separated model, weigh its benefits against its costs and risks, design an evaluation with our own workload, and make sure we can leave.

1A Quick Recap: Classic PostgreSQL

In classic PostgreSQL, one server owns its data directory. Commits flush WAL to the local volume, dirty pages are written back by checkpoints, and full-page images in the WAL protect against torn pages. Each replica is a complete copy: it receives the WAL stream, replays it onto its own copy of every page, and has its own storage. Creating a replica means copying the whole database, and backups mean base backups plus archived WAL. Durability across zones comes from replication, which we configure and operate.

2How Separated Storage Works

In a compute-storage separated design, the database engine still generates WAL, but its storage layer is a distributed service. Amazon Aurora sends log records to storage nodes spread across three availability zones and treats a write as durable when a quorum of copies has acknowledged it; Neon sends WAL to a set of safekeepers that agree on it with a consensus protocol, and page servers rebuild pages from WAL, keeping history in object storage. The details differ by provider, so we read their documentation for the guarantees we rely on.

The consequence is that the compute node does not need to write data pages at all. Pages are materialised by the storage layer when they are needed, so the expensive checkpoint writes and much of the full-page-write overhead move out of the database host or disappear. Read replicas attach to the same shared storage instead of keeping their own copy, which is why they can be created in minutes and why their lag is usually low.

Step throughClassic versus separated storage
  1. Classic: PostgreSQL serverWAL flush, checkpoints, full-page writes on its own volume
  2. Classic: replicaseach replays WAL onto its own full copy
  3. Separated: compute nodesgenerate WAL, cache pages, no data file writes
  4. Separated: log and storage servicequorum writes across zones, rebuilds pages from WAL
  5. Separated: object storagehistory and backups, depending on the provider

5 layers, from the top down. Step through them one at a time.

In the separated model, durability and page maintenance belong to the storage service.

3Benefits

Failover is fast because a new primary does not need its own copy of the data; it attaches to the shared storage and recovers quickly, often within tens of seconds or less, depending on the provider and setup. New read replicas need no data copy, which suits read scaling and short-lived environments; Neon's design also allows cheap branches of a database for testing. Storage grows automatically without resizing volumes. Write I/O on the compute host is lower, since it only ships log records. And backups and point-in-time recovery are handled continuously by the service, which removes a whole class of operational work our team would otherwise own.

4Costs and Risks

The pricing model changes. Some offerings charge per I/O request or for storage in ways that reward or punish particular workloads; a write-heavy service or one with large scans can produce a surprising bill, and some providers offer alternative pricing for I/O-heavy use, which we must compare. There is lock-in: the engine is PostgreSQL-compatible at the protocol and SQL level, but the storage layer, tooling and operational procedures are proprietary, and moving away means a data migration.

There are compatibility limits. Certain extensions, versions or configuration parameters may be unavailable or lag behind community releases, and some low-level behaviours differ. We also give up control: we cannot tune the storage layer, choose its hardware or inspect it deeply during an incident, and our performance depends on a multi-tenant service. None of these rule the architecture out, but they must be in the evaluation.

Comparing the options
CriterionSelf-managed PostgreSQLStandard managed PostgreSQLSeparated storage service
failover timedepends on our toolingtypically a minute or twousually fastest
new read replicafull copy, hours for TBfull copyminutes, shared storage
pricinginstances, volumes, peopleinstances and volumesinstances plus storage and I/O
control and tuningfullmost parametersleast, storage is opaque
exit costlowlow to mediummedium, data migration
Values are typical; measure them for the providers on the short list.

5Evaluating With Our Workload

Vendor benchmarks are not our workload, so we run our own. We pick two or three representative services, such as a write-heavy order service, a read-heavy catalogue and a reporting job, and replay production-like traffic for at least a week against each option. We measure p50 and p99 commit latency, because the quorum write to the storage service may cost more or less than a local flush; read replica lag under load; failover time measured from the client's point of view, including connection errors; and the actual bill for the week, extrapolated.

Then we build a three-to-five-year total cost of ownership model for each option: instances, storage, I/O charges, backups, reserved capacity discounts, and the engineering time to operate it. Self-managed PostgreSQL often looks cheapest on infrastructure and most expensive in people; the separated service often the reverse. The model makes that explicit, and the outcome may well be different per workload.

6Keeping an Exit Path

Whatever we choose, we keep the ability to leave. Applications use the standard PostgreSQL protocol and avoid provider-specific SQL functions unless the benefit is clear and recorded. We prove periodically that we can move a database out using logical replication, publications and subscriptions to a standard PostgreSQL target, with a cutover rehearsal, or with pg_dump and pg_restore for smaller databases. We keep schema migrations in Flyway or Liquibase rather than provider consoles. And we write the decision down, with the conditions under which we would revisit it, such as a price change or a missing extension we come to need.

7Follow-up questions

What would make you choose self-managed PostgreSQL anyway?

Needs the service cannot meet: a required extension or version it does not offer, data residency or regulatory constraints on where and how data is stored, very predictable heavy I/O where per-I/O pricing makes the service far more expensive, the need for deep tuning or custom builds, or an on-premises or multi-cloud strategy. A strong in-house PostgreSQL platform team also lowers the people cost that usually favours the managed options.

Do checkpoints disappear completely in these systems?

On the compute side they change role: the compute node no longer writes back all dirty pages, because the storage service builds pages from WAL. The service still has to materialise pages and manage how much log it keeps, so similar work happens, but inside the storage layer and outside our control.

Is replica lag zero with shared storage?

Not zero. Replicas still have to apply log records to the pages they cache, so they can be slightly behind, but because they do not copy data or replay onto their own storage, lag is usually much lower than with classic streaming replicas. We measure it under our load.

8Conclusion

In this answer, we saw that compute-storage separated databases send WAL to a replicated storage service that rebuilds pages, so durability comes from quorum writes and replicas share storage. That brings fast failover and replicas, elastic storage, less checkpoint overhead and managed backups, at the cost of usage-based pricing, lock-in, compatibility limits and less control. We evaluate with our own workloads for commit latency, replica lag, failover time and multi-year total cost against self-managed and standard managed PostgreSQL, and we keep an exit path through the standard protocol, logical replication and dumps.

What to say in the interviewAbout 90 seconds aloud

Open with

I would first make sure everyone understands what changes. In classic PostgreSQL the server flushes WAL to its own volume, checkpoints write pages back, full-page writes protect against torn pages, and each replica keeps a complete copy.

Then, if they want more

In Aurora or Neon, the compute node sends WAL to a distributed storage service that makes it durable through quorum writes across zones and rebuilds pages from it, so the compute node no longer writes data files and replicas attach to the same storage.

The benefits are real: failover is fast because nothing needs copying, replicas take minutes, storage grows automatically, checkpoint and full-page-write overhead on the host largely goes away, and backups are continuous.

The costs are pricing per I/O or storage that can surprise write-heavy or scan-heavy workloads, lock-in to a proprietary storage layer, limits on extensions and versions, and less control when tuning or debugging.

So I would evaluate with our own workloads: a write-heavy service, a read-heavy one and a reporting job, replayed for a week, measuring p99 commit latency, replica lag, failover time from the client's view and the actual bill, and build a three-to-five-year cost model including people against self-managed and standard managed PostgreSQL. The answer may differ per workload.

And whatever we pick, I keep an exit: standard protocol, migrations in our own tooling, and a rehearsed move out through logical replication or dumps, with the decision and its review triggers written down.

About this answer

Last updated
12 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "Cloud databases such as Amazon Aurora and Neon separate compute from storage: the log is...": https://scrivio-interview-library.netlify.app/databases/storage-internals/877766f830/