DEV Community

Vivesh
Vivesh

Posted on

Overview of the Wanderlust Project

Overview of the Wanderlust Project

Wanderlust is a web-based application designed to serve as a travel management platform, allowing users to explore, book, and manage travel itineraries seamlessly. The project is a classic example of a three-tier architecture, encompassing a frontend, backend, and database, all deployed and managed on the AWS Cloud. It uses modern technologies to ensure scalability, security, and reliability, suitable for handling traffic and data at scale.

Image description

Project Architecture

The Wanderlust application follows a three-tier architecture:

  1. Frontend Tier:

    • Technology: The frontend is built using modern web frameworks like ReactJS. It provides a responsive user interface for users to interact with the application, search for destinations, book travel packages, and manage their trips.
    • Deployment: The frontend is containerized using Docker and deployed on an Amazon Elastic Container Service (ECS) cluster, ensuring scalability and easy management.
  2. Backend Tier:

    • Technology: The backend is developed using Node.js and Express. It acts as the middle layer, handling requests from the frontend and communicating with the database. It is responsible for managing business logic, authentication, and user sessions.
    • Deployment: The backend is also containerized with Docker and deployed on an ECS cluster. The backend services are distributed across multiple containers to ensure high availability.
  3. Database Tier:

    • Technology: The application uses a PostgreSQL database to store user information, travel itineraries, bookings, and other relevant data.
    • Deployment: The database runs on Amazon RDS (Relational Database Service), offering automated backups, scaling, and monitoring to ensure data availability and security.

Tools and Technologies

  1. Amazon Web Services (AWS):

    • Amazon ECS (Elastic Container Service): Used to manage and orchestrate Docker containers for both frontend and backend applications. ECS ensures easy deployment and scaling of services, making it easier to manage containerized workloads.
    • Amazon RDS (Relational Database Service): Hosts the PostgreSQL database. RDS manages database backups, patching, and scaling, ensuring high availability.
    • Amazon S3 (Simple Storage Service): Stores static assets such as images, stylesheets, and scripts, providing a secure and scalable storage solution.
    • Amazon CloudWatch: Monitors application logs, performance metrics, and sends alerts to help troubleshoot any issues.
  2. Docker:

    • The entire application is containerized using Docker, allowing easy deployment and scalability across various environments. Docker ensures that the software runs consistently, regardless of where it is deployed.
  3. CI/CD Pipeline:

    • GitLab CI/CD or Jenkins: Automates the process of building, testing, and deploying the application. CI/CD pipelines make the deployment process faster and more reliable by automating various tasks such as code testing, image building, and deployment.
  4. Infrastructure as Code (IaC):

    • Terraform: Utilized to provision and manage the infrastructure on AWS. It helps define and automate the creation of ECS clusters, RDS instances, networking components, and other resources.
    • Ansible: Assists in configuration management and software provisioning, ensuring that all the instances are set up correctly.
  5. Monitoring and Logging:

    • AWS CloudWatch Logs: Collects and monitors logs from the ECS containers and other services, ensuring that administrators can quickly identify and resolve issues.
    • Prometheus & Grafana: Monitor the health and performance of the application, providing insights into CPU usage, memory usage, and network performance.

Deployment Process

  1. Code Integration and Testing:

    • Developers push the code to the repository on GitLab or another version control platform.
    • GitLab CI/CD or Jenkins triggers the pipeline, automatically testing the code and building Docker images for the frontend and backend.
  2. Building and Pushing Docker Images:

    • Docker images are built and pushed to Amazon Elastic Container Registry (ECR), a secure Docker container registry that integrates seamlessly with ECS.
  3. Provisioning Infrastructure:

    • Terraform scripts provision the required AWS resources, including ECS clusters, RDS instances, and networking components (VPC, subnets, security groups).
  4. Deploying Application on ECS:

    • ECS pulls the Docker images from ECR and deploys them as services. The Application Load Balancer (ALB) is used to distribute incoming traffic to the frontend and backend services, ensuring scalability and availability.
  5. Database Management:

    • The PostgreSQL database on Amazon RDS is configured to support automatic backups, patching, and scaling. Security groups are set up to control access to the database.
  6. Monitoring and Maintenance:

    • Amazon CloudWatch monitors application logs and performance metrics.
    • Prometheus gathers metrics for analysis, while Grafana visualizes these metrics, providing an overview of the application's performance.

Image description

Kudos to Krishna R Acharya for making this project opensource.

Image description

URL - https://github.com/574n13y/wanderlust/tree/via-docker

Conclusion

The Wanderlust project exemplifies the power of containerization and cloud computing by leveraging modern DevOps tools and AWS services. By using a three-tier architecture, the application ensures a separation of concerns, better scalability, and ease of management. Docker containers and AWS ECS facilitate smooth deployments, while services like RDS, CloudWatch, and S3 provide robust infrastructure for storing and managing data securely.

Top comments (0)