How Ant Financial Scales Transactions with Distributed Architecture and Microservices

This article summarizes the key concepts, advantages, and practical implementations of distributed architecture at Ant Financial, covering microservice migration, modular development, database vertical and horizontal sharding, high‑availability mechanisms, gray‑release, and fault‑tolerant settlement workflows.

21CTO
21CTO
21CTO
How Ant Financial Scales Transactions with Distributed Architecture and Microservices

1. Advantages and Concepts of Distributed Architecture

Traditional monolithic applications are fast to develop and deploy, but they suffer from slow compilation, startup, code conflicts, and unreliable releases as the codebase grows.

Microservice architecture addresses these issues by enabling independent service evolution, better handling of unpredictable business changes, and supporting continuous self‑evolution.

Modular development starts from top‑level business design, splitting modules by presentation, logic, and data layers, while ensuring business continuity and data integrity.

2. Distributed Architecture Practice Example – Distributed TA System

The traditional TA system has low parallelism and cannot scale linearly; it relies on large transactions that roll back entirely on failure.

The distributed TA architecture introduces an access layer, business service layer, SOFAStack layer, LAAS, operation toolchain, and governance control, providing a more reasonable yet complex structure.

Key components include:

Access layer: protocol conversion, access control, file transfer, operation console.

Business service layer: core services such as account, transaction, billing, and settlement.

SOFAStack: Ant Financial’s open‑source service components (microservice framework, distributed transaction, task scheduling, message queue, data proxy, tracing, etc.).

Distributed settlement tasks are split, executed, and stored in a flow database, with core services handling transaction, clearing, accounting, and more.

Fault‑tolerant and verification mechanisms cover initialization, file import, clearing, profit calculation, share adjustment, export, secondary clearing, and profit export, allowing rollback at any stage by file, user, or backup point.

3. Ensuring Reliability and Stability in Distributed Architecture

Gray‑release mechanism includes beta release, group release, gray traffic, and full release, allowing user‑level segmentation for faster rollout.

Online full‑link pressure testing uses data access proxies to direct test data to shadow tables, ensuring production‑level reliability without affecting live data.

OceanBase high‑availability leverages Paxos‑based three‑replica deployment, providing strong consistency, continuous availability, automatic master‑slave switching, and fault tolerance across machines, data centers, and cities.

Typical OceanBase deployment scenarios include same‑city three‑data‑center, two‑city three‑center, and same‑city active‑active disaster recovery, each offering low latency, automatic failover, and seamless application deployment.

Overall, the distributed architecture practice at Ant Financial demonstrates how microservices, modular design, database sharding, high‑availability mechanisms, and robust deployment strategies enable scalable, reliable, and maintainable financial systems.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

Microservicesdistributed architecturehigh availabilitydatabase shardingservice governance
21CTO
Written by

21CTO

21CTO (21CTO.com) offers developers community, training, and services, making it your go‑to learning and service platform.

0 followers
Reader feedback

How this landed with the community

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.