Database engineering topic

Database Architecture

Schema design, data modeling, normalization, and database design patterns

23 canonical articles

Normalization vs Denormalization (2026): When Each Wins for Database Performance

Explore the trade-offs between database normalization and denormalization for optimal performance. Learn when to normalize for data integrity and when to denormalize for query speed.

6 minMay 13, 2026
Read

Database Schema Design for Scalability (2026): 12 Patterns DBAs Use in Production

Twelve schema design patterns that survive production scale: primary key strategy, normalization trade-offs, partitioning, sharding boundaries, and indexing rules.

10 minMay 9, 2026
Read

Solving Cache Invalidation and Stampede in Valkey with Debezium CDC

Eliminate stale cache reads and thundering-herd stampedes by streaming MySQL binlog changes to Valkey via Debezium CDC. Full Java setup with embedded engine and XFetch.

MySQL15 minMar 7, 2026
Read

Multi-Tenancy Database Patterns: Schema, Row, and Database-Level Isolation

Design multi-tenant databases — compare schema-per-tenant, row-level-security, and database-per-tenant approaches

PostgreSQL12 minFeb 3, 2026
Read

Multi-Region Database Architecture: Active-Passive, Aurora Global, and Read Routing

Design multi-region database topologies for global latency and DR. Compares active-passive, Aurora Global Database replication, and application-level read routing patterns.

AWS7 minOct 9, 2025
Read

FoundationDB Architecture: ACID Transactions at Distributed Scale

FoundationDB powers Apple iCloud and Snowflake's metadata layer with ACID transactions across distributed nodes. Learn how its ordered key-value core, layer architecture, and simulation testing deliver unmatched reliability.

4 minAug 12, 2025
Read

Redis Streams vs Kafka: Choosing the Right Event Streaming Architecture

Redis Streams and Kafka both handle millions of events per second, but they solve different problems. Compare latency, retention, delivery guarantees, and operational overhead to choose the right architecture.

Redis4 minAug 5, 2025
Read

PostgreSQL Schema Design for Multi-Tenant SaaS: Three Patterns Compared

Compare three PostgreSQL multi-tenant patterns: shared schema with RLS, schema-per-tenant, and database-per-tenant. Includes hash partitioning for shared schema at scale.

PostgreSQL1 minMay 9, 2025
Read

TiDB 8.0: Distributed SQL for Growing Workloads

TiDB 8.0 is the most production-ready version of the distributed SQL database yet. With improved HTAP, stronger MySQL compatibility, and Resource Groups, it's compelling for teams outgrowing single-node MySQL.

TiDB8 minFeb 25, 2025
Read

OpenSearch vs Elasticsearch in 2026: Licensing, Features, and Migration

OpenSearch (Apache 2.0) and Elasticsearch (EL2/SSPL) have diverged. Compare licensing, security features, AI/ML capabilities, and migration complexity for 2026.

8 minJan 14, 2025
Read

TiDB's Raft-Based Replication: How Distributed Consensus Keeps Your Data Safe

TiDB uses Raft consensus protocol through TiKV to replicate every region across three or more nodes. Here's how leader election, log replication, and region management work in practice.

TiDB9 minMay 20, 2024
Read

Demystifying TiDB's Write Path: A Guide to Scalable Data Management

TiDB's write path crosses multiple layers — SQL parser, planner, TiKV region leader, Raft log replication, and 2PC commit — before a transaction is durable. Here's a complete walkthrough.

TiDB9 minMar 25, 2024
Read

Elasticsearch vs Typesense vs Meilisearch: Search Engine Comparison

Compare Elasticsearch, Typesense, and Meilisearch — relevance, speed, operational complexity, and when to use each

11 minSep 14, 2023
Read

Read Replicas vs Caching: When to Use a Read Replica, Redis, or Both

A practical guide to choosing between read replicas and caching layers — replication lag behavior, cache invalidation strategies, thundering herd prevention, tiered read architecture patterns, and decision framework.

PostgreSQL12 minAug 22, 2023
Read

CockroachDB vs Google Spanner vs YugabyteDB: NewSQL Comparison

Compare CockroachDB, Google Spanner, and YugabyteDB — consistency models, PostgreSQL compatibility, and operational costs

12 minJul 10, 2023
Read

Vitess: MySQL Sharding for Kubernetes-Native Workloads

Deploy Vitess for horizontal MySQL sharding — VSchema design, vtgate routing, and migration from single-instance MySQL

MySQL12 minMay 22, 2023
Read

Citus: Distributed PostgreSQL for Multi-Tenant and Analytics Workloads

A production guide to Citus — distributed PostgreSQL for horizontal sharding. Hypertable setup, distribution column selection, colocation for local joins, reference tables, and Citus vs native PostgreSQL partitioning.

PostgreSQL12 minMar 22, 2023
Read

Real-World Examples of Scalable Database Schemas

Analyze real-world database schema designs from companies like Netflix, Uber, and Airbnb. Learn practical patterns for e-commerce, social media, and IoT applications.

13 minDec 13, 2022
Read

Database Sharding Strategies: Hash, Range, Directory, and When to Use Each

A practical guide to database sharding strategies — hash sharding, range sharding, directory-based sharding — with trade-offs, resharding complexity, and decision criteria for MySQL and PostgreSQL.

11 minDec 5, 2022
Read

Data Types and Constraints Selection for Scalable Database Schemas

Optimize database performance by choosing the right data types and constraints. Learn about VARCHAR vs TEXT, INT sizes, ENUM optimization, and constraint best practices.

13 minJul 5, 2022
Read

Schema Versioning and Migration Strategies for Scalable Databases

Implement zero-downtime database migrations with versioning strategies. Learn about Flyway, Liquibase, schema evolution patterns, and rollback strategies.

14 minApr 26, 2022
Read

Partitioning and Sharding Techniques for Database Scalability

Master horizontal and vertical partitioning, plus database sharding strategies for handling billions of records. Learn partition pruning, shard key selection, and cross-shard query optimization.

10 minApr 12, 2022
Read

Database Schema Design Fundamentals for Scalability

Learn the fundamental principles of database schema design for building scalable applications. This guide covers entity relationships, primary keys, foreign keys, and normalization concepts essential for high-performance databases.

5 minMar 1, 2022
Read