Is a transaction handled by only one TiDB server in the cluster?

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: 一个事务是不是只有集群中的一个tidb server在处理?

| username: 逍遥_猫

Is a transaction handled by only one TiDB server in the cluster?
In a TiDB cluster with 3 TiDB servers, only one owner handles the same transaction, right? The other 2 are used to ensure high availability?

| username: 啦啦啦啦啦 | Original post link

Yes, the TiDB server only parses SQL, forwards actual data read requests to the underlying storage nodes, assembles the returned results, and finally returns the query results to the client. It is generally used in conjunction with load balancing to distribute the pressure across multiple nodes. If a crash occurs during the execution of a transaction, the transaction on this TiDB server also fails. Multiple nodes can only ensure the high availability of the TiDB server.

| username: forever | Original post link

TiDB is a Shared Nothing architecture. The TiDB server is a stateless computing node that does not store data and can dynamically increase the number of nodes. Multiple servers are used to share the load, with each server running a portion of the transactions.

| username: 逍遥_猫 | Original post link

Does this mean that a transaction can run on multiple TiDB servers separately? How is transaction consistency ensured?

| username: HACK | Original post link

A transaction can only be executed on one TiDB server.

| username: forever | Original post link

Execute outside of an entity on a server, each server can run different entities.

| username: OnTheRoad | Original post link

| username: system | Original post link

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.