Skip to content

Latest commit

 

History

History
98 lines (61 loc) · 1.95 KB

README.md

File metadata and controls

98 lines (61 loc) · 1.95 KB

EventHub

EventHub Logo

EventHub is a Go-based event management system that leverages Protocol Buffers (Protobuf), gRPC, and MongoDB. It is designed with high-performance logging using Uber Zap and modularized dependency injection through Uber FX.

Getting Started

Prerequisites

Ensure you have the following installed:

  • Go 1.20+: The language this project is written in. Installation instructions.

  • MongoDB: The database management system used. Create a free MongoDB Atlas cluster here and follow the installation steps.

  • Mage: A build tool CLI, that automatically uses Go functions as Makefile-like runnable targets. Installation instructions.

Setup

  1. Clone the Repository:
git clone https://github.com/villaleo/eventhub.git
cd eventhub
  1. Install Dependencies:

After installing the prerequisites, run this command to install all other required tools.

mage
  1. Generate Protobuf Files: After setup, generate the necessary protobuf files.
mage gen

Starting the Server

  1. Default Port:

Starts the server with the default port 50051.

mage server:run
  1. Using a Custom Port:

Starts the server using a specific port.

mage server:start 50051

Starting the Client

  1. Default Address:

Runs the client using the default address localhost:50051.

mage client:run
  1. Using a Custom Address:

Starts the client using a specific address.

mage client:start localhost:50051

Linting

Linting is ran by default before starting the server. It is required and cannot be disabled.

mage lint

All Commands

To see all the commands available for this project, run this command.

mage -l

Or checkout a specific target's usage.

mage -h server:start