1.Three-tier architecture
Three-tier architecture splits a system into a client (what the user interacts with), an application tier (business logic), and a database tier (persistent storage) — each tier only talks to its immediate neighbor.
Key features
- Client tier: the user-facing layer — browser, mobile app, or another API consumer
- Application tier: business logic, validation, and orchestration — no direct client access to storage
- Database tier: persistent storage — the client never talks to it directly
- Each tier can be scaled, deployed and replaced independently of the others
- The most common default shape for a new web system before any specialization is added
The three tiers
- Client — browser, mobile app
- leads to Application (request)
- Application — business logic, validation
- leads to Database (query)
- leads to Client (response)
- Database — persistent storage
- leads to Application (result)
Command
client --request--> application --query--> database
client <--response-- application <--result-- database
client never talks to the database directlyClient (presentation) → application (business logic) → database (storage) — each tier only talks to its immediate neighbor.