mohammed firdous
blogprojectsopen sourcediagramsexperiencecertifications

Cruddur

A visual explanation of the Cruddur microblogging platform's cloud architecture.

This section provides a technical deep-dive into the architecture of the Cruddur microblogging platform. The diagrams below illustrate how the system is designed for scalability, reliability, and cost-efficiency using modern cloud technologies.

Cruddur architecture overview
Figure 1: High-level Cruddur architecture — click to view full size.
VPC networking setup
Figure 2: VPC networking with public and private subnets.
Frontend hosting on S3 and CloudFront
Figure 3: React frontend on S3 delivered via CloudFront.
ALB routing to ECS Fargate
Figure 4: ALB routing traffic to ECS Fargate backend services.
CI/CD pipeline with CodePipeline
Figure 5: CI/CD pipeline built with AWS CodePipeline.
CodePipeline stages
Figure 6: CodePipeline source, build, and deploy stages.
DynamoDB and Lambda data layer
Figure 7: DynamoDB for messaging with Lambda stream processing.

Architectural Overview

The Cruddur architecture is designed to be a modern, scalable, and cost-effective web application. It separates the user interface (frontend) from the business logic (backend).

  • The frontend is a React application that users interact with in their browser.
  • The backend is a Python Flask application that handles tasks like creating posts, managing user data, and sending messages. It runs in Docker containers managed by AWS Fargate, which automatically handles the server infrastructure.
  • Data is stored in two different databases based on its type:
    • PostgreSQL (RDS): For structured data like user profiles and posts.
    • DynamoDB: For real-time chat messages, which require very fast reads and writes.
  • Security is handled by AWS Cognito for user sign-in and sign-up.

Why This Architecture?

This design was chosen for several key reasons:

  • Scalability: By using AWS Fargate and serverless components, the application can automatically scale to handle more users and traffic without manual intervention.
  • Reliability: Running services across multiple AWS Availability Zones and using managed services like RDS and DynamoDB makes the application highly available and resilient to failures.
  • Cost-Effectiveness: The serverless-first approach means you only pay for the resources you use, which is more cost-effective than running servers 24/7.
  • Maintainability: Separating the frontend and backend allows different teams to work on them independently, and the use of containers ensures a consistent environment from development to production.