Evolution of a Startup's Backend Architecture: From Single Server to Distributed System
After leaving Baidu in 2015, the author recounts nearly two years of evolving a startup’s backend architecture—from a single‑server Tomcat setup to multi‑node clusters with Nginx reverse proxy, database sharding, caching, session sharing, and service‑oriented design—highlighting challenges, optimizations, and lessons learned.
After leaving Baidu in June 2015, the author joined a startup and, over nearly two years, documented the evolution of the system architecture and the reasons behind each optimization.
In the early stage, limited funds led to a single‑server architecture: a Linux machine with a fixed IP running Tomcat to serve PC‑only web pages. This monolithic setup caused service instability, performance bottlenecks, and difficulty tuning the JVM because business logic, I/O, and CPU‑intensive tasks were all packed into one process.
When additional funding allowed more servers, the architecture shifted to a cluster with Nginx as a reverse proxy, multiple application servers, and separate database and file storage. This improved stability and concurrency, but the single‑node database became a new bottleneck, prompting the introduction of caching.
Further refinements addressed Nginx session‑sticky load, uncacheable queries, and chaotic file management. The next iteration introduced session sharing via a cache service, read/write database separation, and dedicated file storage, laying the groundwork for vertical splitting of core and non‑core services.
The final distributed architecture adopted layered, service‑oriented design, with internal simple systems illustrated in the diagram below.
With matured technology, the platform can expose core services such as caching, message queues, and domain‑specific solutions (e.g., ABS packaging for small‑scale financial products) to external companies, similar to cloud‑style offerings.
Source: http://www.cnblogs.com/loveyou/p/6931136.html
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.
Architecture Digest
Focusing on Java backend development, covering application architecture from top-tier internet companies (high availability, high performance, high stability), big data, machine learning, Java architecture, and other popular fields.
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.
