Skip to content

Large Scale Distributed Systems (SDLE) Project (2024/2025): MSc in Informatics and Computing Engineering @ FEUP

Notifications You must be signed in to change notification settings

kikoveiga/feup-sdle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

73 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SDLE Assignment

SDLE Assignment of group T07G14.

Group members:

  1. Bruno Machado ([email protected])
  2. João Padrão ([email protected])
  3. José Francisco Veiga ([email protected])

Introduction

  • This project, entitled Shopping Lists on the Cloud, centres on the implementation of a distributed system that uses conflict-free replicated data types (CRDTs) to guarantee consistency between replicas in a shopping list management application. The application allows users to create, share and manage shopping lists collaboratively, even in offline-first scenarios.

Main Features

  • CRDT implementation: Use of CCounters to manage item quantities in a conflict-free way.

  • Distributed architecture: Based on ZeroMQ for robust communication between clients and servers, employing the Paranoid Pirate Pattern to increase fault tolerance. The server is composed of a broker and multiple workers. The broker is responsible for load balancing the clients' requests among the workers, which are responsible for processing them.

  • Persistence and replication: MongoDB is used to persist data on the server side, guaranteeing durability and allowing recovery after failures.

  • Objective: To demonstrate the viability of cloud-supported, conflict-free collaborative applications with minimal friction for the user.

Execution

Below are the instructions to build and run the project. This is mainly focused on Ubuntu, but the links below also provide instructions for other operating systems.

Prerequisites

To build and run the project, ensure the following software is installed:

  • CMake (version 3.30 or higher): you can download and install CMake from the official website.

  • MongoDB: Follow the instructions on the official website, here is a guide to install it on Ubuntu.

  • MongoDB C++ Driver (mongocxx and bsoncxx): here is a guide to install it on Ubuntu. Make sure to install it with the Boost polyfill option.

Build Instructions

  • Clone the repository and navigate to the project directory:

    git clone <repository_url>
    cd g14
  • Init the submodules:

    git submodule update --init --recursive
  • Build the project using CMake:

    cmake -S . -B build
    cmake --build build

Run Instructions

  • Start the MongoDB server:

    sudo systemctl start mongod
  • Run the broker:

    cd build
    ./main_broker
  • Run the workers:

    ./main_worker
  • Run the client:

    ./client