InterviewStack.io LogoInterviewStack.io

Database Scalability and High Availability Questions

Architectural approaches and operational practices for scaling and maintaining database availability. Topics include vertical versus horizontal scaling trade offs; replication topologies, leader and follower roles, read replicas and replica lag; read write splitting and connection pooling; sharding and partitioning strategies including range based, hash based, and consistent hashing approaches; handling hot partitions and data skew; federation and multi database federation patterns; cache layers and cache invalidation; rebalancing and resharding strategies; distributed concurrency control and transactional guarantees across shards; multi region deployment strategies, cross region failover and disaster recovery; monitoring, capacity planning, automation for failover and backups, and cost optimization at scale. Candidates should be able to pick scaling approaches based on read and write patterns and explain operational complexity and trade offs introduced by distributed data.

EasyTechnical
43 practiced
Explain ACID properties (atomicity, consistency, isolation, durability) and contrast them with BASE/eventual consistency models. As a backend developer, give clear examples of when you would prefer strong ACID guarantees versus eventual consistency and list application-level patterns to cope with eventual consistency.
HardTechnical
32 practiced
Design an algorithm and automation to detect sudden replica lag spikes in asynchronous replication and mitigate them automatically. Specify sensible thresholds, anomaly-detection logic (trend vs absolute), and automated remediation actions (e.g., route reads away, promote a replica, throttle writes, pause heavy queries). Include safety checks to avoid unsafe promotions.
EasyTechnical
30 practiced
Compare common cache strategies used between application and database: cache-aside, write-through, and write-behind (write-back). For each strategy describe behavior on read and write, consistency guarantees, typical use cases, and pitfalls related to invalidation, data loss, or stale reads.
EasyTechnical
34 practiced
Your social network uses asynchronous read replicas to scale timeline reads. Explain what replica lag is, why it happens, and outline at least three strategies a backend developer can use to mitigate stale reads for user timelines without sacrificing read scalability. Include both client- and server-side techniques.
EasyTechnical
41 practiced
What are the essential database monitoring metrics a backend developer should track for capacity planning and high availability? Provide categories of metrics (resource, replication, performance) and at least two specific metrics per category with brief rationale for each.

Unlock Full Question Bank

Get access to hundreds of Database Scalability and High Availability interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.