58.com Database Architecture Design Overview
This article presents a comprehensive overview of 58.com’s database architecture, covering availability through replication and dual‑master setups, read‑performance enhancements via indexing, replicas and caching, consistency strategies, rapid horizontal scaling, sharding patterns, and practical SQL considerations alongside Codd’s 12 relational rules.
The article outlines 58.com’s database architecture design, focusing on availability, read/write performance, consistency, and scalability.
Availability design : Uses replication and redundancy, with master‑slave and dual‑master configurations to ensure high read and write availability, while addressing master‑slave inconsistency.
Read performance : Improves through extensive indexing (different indexes per database), adding read replicas, and employing a service‑cache‑data layer that avoids read/write separation and mitigates inconsistency.
Consistency solutions : Introduces middleware routing writes to the master and reads to the master within a synchronization window, or simply routes all operations to the master; also uses a double‑eviction cache strategy to resolve cache‑database mismatches.
Scalability : Describes rapid horizontal scaling by converting N databases to 2N using dual‑master “master‑as‑slave” mode, and discusses schema evolution via log‑based or dual‑write methods, as well as sharding strategies for single‑key, one‑to‑many, many‑to‑many, and multi‑key tables.
SQL practices : Advises limited use of complex queries, joins, subqueries, triggers, UDFs, and transactions due to performance impact, and presents techniques for pagination, IN queries, and non‑partition key queries in a sharded environment.
The article also revisits Codd’s 12 rules for relational databases and offers practical advice such as minimizing reliance on database‑specific features and defining entity relationships with clear ownership and cardinality.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
IT Architects Alliance
Discussion and exchange on system, internet, large‑scale distributed, high‑availability, and high‑performance architectures, as well as big data, machine learning, AI, and architecture adjustments with internet technologies. Includes real‑world large‑scale architecture case studies. Open to architects who have ideas and enjoy sharing.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
