Skip to content

An online platform where users can create, comment on, and interact with forum topics. The system is designed with a microservices architecture, ensuring scalability and maintainability.

Notifications You must be signed in to change notification settings

owlCoder/le_reddit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

Le Reddit Logo Le Reddit

Techology Stack

Azure JWT NPM React React Router TailwindCSS

Languages

JavaScript TypeScript C# .Net

Supported Browsers

Brave Edge Firefox Google Chrome Opera Safari

Dev Dependencies

Docker ESLint Babel

Table of Contents

Project Overview

This project is a Reddit clone that allows users to create, comment, and interact with forum topics. It includes separate services for sending notifications and checking service availability.

Features

User Interface (Web Role)

  • User registration
  • User login
  • User profile modification
  • Create new posts
  • Comment on posts
  • Search and sort posts by title
  • Delete posts or comments
  • Upvote and downvote posts

User Registration

Users register by providing:

  • First Name
  • Last Name
  • Address
  • City
  • Country
  • Phone Number
  • Email
  • Password
  • Profile Picture

Notification Service

  • Sends emails to subscribed users when a new comment is posted.
  • Uses separate Worker Role service called NotificationService (3 instances).
  • Utilizes services like Postmark or SendGrid for email delivery.

Health Monitoring Service

  • Separate Worker Role service called HealthMonitoringService (2 instances).
  • Monitors RedditService and NotificationService every 1-5 seconds.
  • Logs the status in a HealthCheck table.

Health Status Service

  • Web Role application for visual representation of service availability.
  • Displays uptime percentage for the last 24 hours.

Installation

  1. Clone the repository:

    git clone https://github.com/owlCoder/le_reddit.git
    cd le_reddit
  2. Install dependencies:

    npm install
  3. Set up environment variables:

    cp .env.example .env
    # Edit .env with your configuration
  4. Run the application:

    npm start

Usage

  • Navigate to http://localhost:5173 in your browser.
  • Register a new user or log in with an existing account.
  • Create, view, and interact with posts and comments.

API Endpoints

User Endpoints

  • POST /register - Register a new user
  • POST /login - Log in a user
  • PUT /user/:id - Update user profile

Post Endpoints

  • POST /posts - Create a new post
  • GET /posts - Get all posts
  • GET /posts/:id - Get a specific post
  • PUT /posts/:id - Update a post
  • DELETE /posts/:id - Delete a post

Comment Endpoints

  • POST /posts/:postId/comments - Add a comment to a post
  • DELETE /comments/:id - Delete a comment

Contributing

  1. Fork the repository
  2. Create a new branch (git checkout -b feature-branch)
  3. Commit your changes (git commit -am 'Add new feature')
  4. Push to the branch (git push origin feature-branch)
  5. Create a new Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contact

Danijel Jovanović - jovanovic.pr55.2020@uns.ac.rs

Project Link: https://github.com/owlCoder/le_reddit


Feel free to customize the links, images, and additional details to match your specific project needs.

About

An online platform where users can create, comment on, and interact with forum topics. The system is designed with a microservices architecture, ensuring scalability and maintainability.

Resources

Stars

Watchers

Forks