Operations 4 min read

Why Xi’an Health Code Crashed: Static Assets, No CDN, and 125 Gbps Bandwidth

A detailed post examines why the Xi’an health‑code service collapsed, showing that the lack of CDN for static assets and the resulting 125 Gbps bandwidth demand at 33 k QPS overwhelmed a single data‑center link, rather than any server‑side QR‑code generation issue.

Programmer DD
Programmer DD
Programmer DD
Why Xi’an Health Code Crashed: Static Assets, No CDN, and 125 Gbps Bandwidth

After the “Xi’an Health Code” outage, a deeper technical analysis reveals that the failure was not caused by server‑generated QR‑code images but by the way static assets (js, css, img) are delivered.

One contributor, 卢兴民, posted the refresh‑QR‑code API response, showing the data is normal. Another answer confirmed that no low‑level image generation occurs on the server.

The core issue is that all static resources are served from a single entry point without a CDN. The total size of js/css/img files is roughly 500 kB. With a peak request rate of about 33 000 QPS, the required bandwidth is estimated at 125 Gbps (33 000 × 500 bytes × 8 bits), which a single data‑center network card cannot sustain.

As of 5 January 2022, the Xi’an health‑code system had not yet moved static assets to a CDN, raising doubts about its ability to handle future traffic spikes.

Below are screenshots of the API response and the bandwidth calculation.

QR code refresh API response
QR code refresh API response
Bandwidth calculation
Bandwidth calculation
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.

performancenetworkCDNweb architecturestatic assetsHealth Code
Programmer DD
Written by

Programmer DD

A tinkering programmer and author of "Spring Cloud Microservices in Action"

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.