How do compute, storage, database, and networking services typically work together in a simple three tier web application architecture?
Short answer
In a typical three tier architecture, a networking layer built with VPC defines isolated private and public subnets, a compute layer using EC2 instances or containers runs the actual application code within those subnets, a database layer using RDS stores structured application…
Advertisement
AModel answer
In a typical three tier architecture, a networking layer built with VPC defines isolated private and public subnets, a compute layer using EC2 instances or containers runs the actual application code within those subnets, a database layer using RDS stores structured application data securely in private subnets, and a storage layer using S3 holds static assets like images, with all of these layers connected together through carefully configured security groups and routing rules that control exactly how traffic flows between them.
Example
// Simplified three tier flow // Public subnet: Load Balancer // Private subnet: EC2 application servers // Private subnet: RDS database
Real-world example
A startup building its first production application places its EC2 web servers in a public facing subnet behind a load balancer, while keeping its RDS database in a private subnet completely inaccessible from the public internet, following the standard three tier architecture pattern.
Likely follow-ups
- Why is it a best practice to keep a database in a private subnet rather than a public one?
- How does this basic three tier pattern evolve as an application scales?
Related topics