A simple microservice app built with Node.js, React.js and Express. Allows users to add posts and comments, rejects comments containing word "orange". Demonstrates microservices architecture for smaller, independent services.
WIP
This is a simple microservice application built with Node.js, React.js and Express. It allows users to add post titles and comments, while comments containing the word "orange" are rejected. The application consists of 5 services and a react frontend each located in its own folder.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
You will need to have Node.js and npm installed on your machine to run this application. You can download the latest version of Node.js from the official website: https://nodejs.org/
The application consists of five microservices: post service, comments service, query service, moderation service, and an event bus. Each service is located in its own folder, and to run each service, you will need to navigate to the folder and run the following commands:
cd <service-folder>
npm install
npm dev # to start a development server
client
directorynpm install
to install dependenciesnpm run start
to start a local development serverThe application uses a JavaScript object as an in-memory database to store the post titles and comments. This allows for quick and easy storage and retrieval of data without the need for a persistent database.
Please note that this application is for learning purposes only and is not intended for production use. The in-memory database may not be suitable for larger applications and a persistent database such as MongoDB should be used instead.