Understanding Server‑Side Architecture: Layers, MVC, and SOA
This article explains the layered server‑side architecture model, the role of each layer, the MVC pattern and its communication flows, Maven‑based project modularization, and an overview of Service‑Oriented Architecture, providing a practical guide for designing flexible backend systems.
This article provides a concise discussion of a project system architecture splitting model, describing the purpose of each layer and how services are offered in an SOA‑oriented programming approach.
Server Architecture Solution
Using a visual metaphor, the traditional server software is depicted with the operating system (typically Linux) at the bottom and business functions and services at the top. Adding architectural layers such as cache or data‑access layers increases flexibility and scalability, and the illustrated stack remains reasonable.
MVC Framework
MVC (Model‑View‑Controller) separates data from presentation, allowing the same data to be displayed in various ways without modifying the Model layer.
The diagram shows communication among MVC modules: the Controller can freely interact with Model and View, fetching data from Model and instructing View how to render it. Direct Model‑View communication is prohibited to reduce coupling; a red arrow indicates this restriction, while a double‑yellow line marks the forbidden crossing. Solid lines denote normal communication, and dashed lines indicate optional or conditional links.
# Model‑Controller Communication
Model and Controller are connected by solid lines, meaning Model cannot arbitrarily access Controller, but Controller can receive broadcasts from Model when data changes. Interested Controllers receive the broadcast and update the corresponding View.
The Controller orchestrates program logic, linking Model and View so that the View reflects the Model’s state as directed by the Controller.
# View‑Controller Communication
Views need to communicate with Controllers for user actions. Instead of calling Controller methods directly, a "Target" mechanism is used: the Controller tells the View which Target to invoke when an event occurs, then the Controller processes the event and updates the View.
# Delegate Method
Another way for View‑Controller interaction is via delegation (proxy).
Project Layer Division
Real Maven‑managed projects are modular, each module having its own pom.xml. Modules are linked through inheritance and aggregation, following the design principle of high cohesion and low coupling.
A simple Maven module structure is illustrated below, highlighting dependency transitivity.
Typical modules: Web (provides Actions/Controllers), Service (business logic), Manager (transactional data handling), Dao (ORM), Domain (POJOs), RPC (external resource calls), Remoting (service exposure). API packages define protocols, while Client packages may contain business logic and consume system resources.
SOA Framework
SOA (Service‑Oriented Architecture) is a style that supports service‑centric design, focusing on services, service‑based development, and service interfaces as a way of thinking.
Reference links: http://2sxc.org/en/Blog/post/javascript-mvc-you-need-a-good-mvc-framework http://www.jianshu.com/p/79cc250be1b2
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.
