Databases 8 min read

Understanding Tencent Cloud's TDSQL Distributed Relational Database Architecture and Features

This article explains the motivations behind distributed databases in high‑risk industries, introduces Tencent Cloud's TDSQL as a market leader, and details its architecture—including load balancing, SQL engine, compute and storage separation, raft‑based strong consistency, lossless upgrades, high‑availability failover, and an intelligent DBA platform.

Refining Core Development Skills
Refining Core Development Skills
Refining Core Development Skills
Understanding Tencent Cloud's TDSQL Distributed Relational Database Architecture and Features

Many readers working in internet companies mistakenly believe that internet services demand the highest technical standards, yet sectors like high‑frequency trading, banking, securities, and telecommunications actually require far stricter latency, consistency, and security guarantees.

Historically, these industries relied on Oracle and IBM DB2, but a recent IDC report shows that domestic solutions have advanced, with Tencent Cloud's TDSQL now ranked as a leader in China's distributed relational database market.

TDSQL is a transparent distributed database that lets applications interact as if using a single‑node database, abstracting away sharding, replication, and scaling complexities.

The system consists of three main components: management nodes, compute nodes, and storage nodes, enabling independent scaling of compute and storage resources.

Incoming user requests are routed by a load balancer to the SQL engine, which parses SQL, determines the relevant data shards from MetaCluster metadata, and dispatches queries to multiple data nodes; results are aggregated before returning to the client, providing a unified table view.

Each data node (SET) contains a Master and one or more Slaves; data is partitioned by a shard key and replicated using the Raft protocol, ensuring strong consistency by requiring acknowledgment from at least one Slave before confirming a write.

Within each node, an Agent runs alongside a MySQL instance, similar to a sidecar in service‑mesh architectures; the Agent monitors MySQL status and enables lossless upgrades by allowing the Agent to be updated independently of the database process.

In case of Master failure, the Agent reports the issue to the MetaServer, triggers a downgrade to Slave, and elects a new Master automatically, achieving high availability without manual intervention.

TDSQL also offers the "Bian Que" intelligent DBA platform, which automatically detects anomalies such as problematic SQL, expansion errors, and lock issues, improving operational efficiency and supporting large‑scale cluster management.

Overall, TDSQL demonstrates how strong consistency, lossless upgrades, and high availability are realized through its architecture, and its success in Chinese financial, public service, and telecom sectors highlights the growing strength of domestic database solutions.

Images illustrating the architecture and platform are included throughout the article.

High AvailabilityDistributed DatabaseTDSQLintelligent DBAlossless upgradeStrong Consistency
Refining Core Development Skills
Written by

Refining Core Development Skills

Fei has over 10 years of development experience at Tencent and Sogou. Through this account, he shares his deep insights on performance.

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.