Quick revision
The short answer
I would lead it as an evidence-based decision rather than a debate between two camps. First quantify the problem: data size, write rates, latency needs and which parts of the system really need horizontal scale. Then compare in-house sharding (control, a familiar engine, but years of owning routing, resharding and cross-shard work) with distributed SQL or a managed sharding layer (faster to a working system, but vendor risk, cost per node and different failure modes) through a time-boxed proof on real workloads and a five-year total cost including people, and choose the path that keeps exit options open.
What to remember
In this answer, we saw how to lead a build-versus-buy decision on scaling the data platform. We start by quantifying growth per domain, because often only a few domains need horizontal scale. We weigh in-house sharding's control and familiarity against years of owning a distributed layer, and distributed SQL's speed against vendor risk, cost and new failure modes. A joint, time-boxed proof with real workloads and failure tests, and a five-year cost that includes people, makes the decision on evidence. Service boundaries and standard SQL keep exit options open, and involving both groups makes the decision stick.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
I would lead it as an evidence-based decision rather than a debate between two camps. First quantify the problem: data size, write rates, latency needs and which parts of the system really need horizontal scale. Then compare in-house sharding (control, a familiar engine, but years of owning routing, resharding and cross-shard work) with distributed SQL or a managed sharding layer (faster to a working system, but vendor risk, cost per node and different failure modes) through a time-boxed proof on real workloads and a five-year total cost including people, and choose the path that keeps exit options open.
Why this question is asked
A board-level growth plan turns a technical choice into a strategic one: whatever we choose will shape hiring, cost and reliability for years. Two groups with strong opinions usually means both have a point, and the leader's job is to make the decision on facts, make it stick, and keep the losing group engaged. Interviewers ask this to hear how we structure a decision, not which product we like. In this answer, we will start by quantifying the problem, look honestly at each option, design a fair proof of concept, compare total cost over five years, and see how to keep exit options and bring people along.
1Start by Quantifying the Problem
20x growth in five years sounds like it needs a new architecture, but the first job is to turn it into numbers. Suppose today's main database holds 2 TB and peaks at 4,000 writes per second. 20x data is 40 TB, and if writes grow at the same rate, 80,000 writes per second. Those numbers lead to very different conclusions depending on where the growth sits. Often most of it is in a few tables, such as events or audit logs, that could move to a different store or be partitioned and archived, while the core transactional data grows only 3x and fits a single well-run primary for years.
So we break the projection down by domain: which tables grow, how fast, what latency each workload needs, and what consistency it requires. The outcome is often that only one or two domains truly need horizontal write scale. That already changes the question from 'how do we shard the company' to 'how do we scale these two domains'.
2The Case for In-House Sharding on PostgreSQL
The group that wants to build has real arguments. PostgreSQL is familiar: the team knows its performance, its tooling and its failure modes, and every engineer can debug it. We keep full control over versions, extensions and hardware, and single-shard queries run at single-node speed.
The honest cost is that the company becomes the owner of a distributed database layer. Someone must build and maintain routing, resharding when shards fill up, cross-shard queries and reporting, cross-shard transactions or the patterns that avoid them, schema migrations across all shards, backups and restores per shard, and on-call for all of it. That is not a project; it is a product with a team of its own, for as long as the company exists. Companies that built this well typically dedicated several senior engineers to it for years.
3The Case for Buying Distributed SQL
The group that wants to buy also has real arguments. A distributed SQL database such as CockroachDB, YugabyteDB, Spanner or TiDB, or a managed sharding layer such as Citus for PostgreSQL or a Vitess-based service for MySQL, gives a working horizontally scaled system much faster. Rebalancing, replication and failover are the vendor's problem.
The costs are different, not absent. There is vendor risk: pricing changes, the product's roadmap, or the vendor's own survival. Cost per node is often higher than plain PostgreSQL, and consensus replication means three copies of data by default. Failure modes are new: write latency includes consensus round trips, contention shows up as retry errors, and the team must learn new tools at 3 a.m. And SQL compatibility is partial: PostgreSQL-compatible products differ in extensions, some features and isolation behaviour, so our application may need changes.
| Factor | In-house sharding on PostgreSQL | Distributed SQL or managed sharding |
|---|---|---|
| Time to a working system | Long: routing, resharding, tooling | Short: built in |
| Control | Full: versions, extensions, hardware | Limited to the product's options |
| Ongoing ownership | A platform team for years | Vendor operates the hard parts |
| Failure modes | Known engine, custom layer on top | New ones: consensus latency, retries |
| Cost profile | Cheaper nodes, expensive people | Higher cost per node, fewer people |
| Compatibility | Full PostgreSQL | Partial; test the application |
4Run a Fair, Time-Boxed Proof
Opinions end where measurements start. I would set up a proof of concept of six to eight weeks with a small team drawn from both groups, so neither side can dismiss the result. The proof uses our real workload: a copy of production data scaled up, the top 20 queries and transactions by volume, and realistic concurrency. Both options are tested against the same written success criteria agreed before the start, such as p99 latency for the checkout transaction under 50 ms at 5x today's load, and the behaviour during failures: kill a node, partition a zone, add capacity under load, run a schema migration.
For the in-house option, the proof cannot build everything, so it builds the riskiest part, usually resharding a live shard, and estimates the rest. For the buy option, we include the vendor's support response and the application changes we needed for compatibility, because those are the costs that surprise teams later.
5Compare Total Cost Over Five Years
The board is asking about five years, so the cost comparison covers five years. It includes infrastructure at each stage of growth, licences or service fees, and, the item most often left out, people: the engineers needed to build and operate each option, and the opportunity cost of what they would otherwise build. As an illustration only, an in-house layer might need four senior engineers full time, which can easily cost more per year than the difference in node prices. We also price the risks: what a migration away from the vendor would cost, and what a resharding outage would cost the business.
- Quantify growth per domainsize, writes, latency, consistency
- Does more than a few domains need horizontal writes?YesEvaluate both options broadlyNoScale only those domains
- Time-boxed proof on real workloadsjoint team, agreed success criteria, failure tests
- Five-year total cost including peopleplus cost of exit and of outages
- Decide, document, and set review triggerskeep exit options open
5 steps in order. Play them, or step through them one at a time.
6Keep Exit Options and Bring People Along
Whichever path we choose, we make it reversible where we can. Data access goes through clear service boundaries, so only the service that owns a domain talks to its database. We prefer standard SQL and avoid product-specific features unless they are worth the lock-in. We keep a tested path to export data, such as logical replication or change data capture. Then if the chosen platform disappoints, moving one domain is a migration project, not a rewrite of the company.
Finally, the people. I would write the decision down with its evidence and the criteria that would make us revisit it, such as cost per transaction passing a threshold. The group whose option lost should have shaped the criteria and the proof, and should have a clear role in the result, for example owning the exit path or the performance testing. A decision that one group feels was imposed on it tends to be quietly undermined.
7Follow-up questions
What if the proof shows both options meet the criteria?
Then the cheaper option over five years, including people and risk, wins, and if that is close, the one with lower operational burden for our team as it actually is today. Meeting the criteria equally usually means buying is better, because it frees engineers to work on the product.
How do you stop the proof of concept from becoming a permanent project?
By fixing the time box and the deliverable at the start: a written comparison against the agreed criteria by a date. Extensions need a specific unanswered question and an owner's approval.
Is there a middle path?
Often, yes. Managed sharding layers such as Citus keep the PostgreSQL engine while handling distribution, and splitting the growth domains into separate databases by service can delay sharding entirely. The quantification step usually reveals these options.
8Conclusion
In this answer, we saw how to lead a build-versus-buy decision on scaling the data platform. We start by quantifying growth per domain, because often only a few domains need horizontal scale. We weigh in-house sharding's control and familiarity against years of owning a distributed layer, and distributed SQL's speed against vendor risk, cost and new failure modes. A joint, time-boxed proof with real workloads and failure tests, and a five-year cost that includes people, makes the decision on evidence. Service boundaries and standard SQL keep exit options open, and involving both groups makes the decision stick.
Open with
I would make this an evidence-based decision and not a contest between the two groups. First I would quantify the problem per domain: current and projected data size, write rates, latency requirements and consistency needs.
Then, if they want more
Very often 20x growth sits in a few tables, like events or logs, while the core transactional data grows much less, so only one or two domains may really need horizontal write scale. Then I would lay out both options honestly.
In-house sharding on PostgreSQL gives full control and a familiar engine, but the company owns routing, resharding, cross-shard queries, migrations across shards and on-call, for years, which really means a dedicated platform team.
Buying distributed SQL, or a managed layer like Citus or a Vitess-based service, gets us to a working system much faster, but adds vendor risk, higher cost per node, different failure modes like consensus latency and retry errors, and partial SQL compatibility.
To decide, I would run a six to eight week proof with engineers from both groups, on our real workload at several times today's load, with success criteria and failure tests agreed in advance, and build a five-year total cost that includes people and the cost of exiting.
Whatever we choose, data access goes through service boundaries and standard SQL where possible, so changing platforms later is a migration and not a rewrite. I would document the decision with review triggers and give the other group a real role in the outcome.
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.
- Official documentation
- PostgreSQL documentation, MySQL reference manual
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 "A board-level growth plan predicts 20x data growth in five years. One group wants to...": https://scrivio-interview-library.netlify.app/databases/partitioning-and-sharding/86216cf01d/