NestJS Microservices -Event-Driven Architecture with RabbitMQ
In this article you will learn how to create an Event-Driven Architecture with RabbitMQ using NestJS. In order to create the microservice structure, we will have two apps. The first one will be called Admin and the second one will be called Main. They will have two different databases. The Admin app will use MySQL as a database and the Main app will use MongoDB as a database.
Both apps will use TypeORM to use the database and create and manipulate data. Both apps will communicate with each other using RabbitMQ events. So, if we create a product in the Admin app, RabbitMQ will send an event to the Main app so we can create the same product. In the picture below you can see how the app will look like.
To check how this Microservice Architecture is created step by step, check the video below:
The frontend of this app can be built on Angular, React and VueJs. Below I have provided the links for them:
Angular and NestJS Microservices: https://www.youtube.com/playlist?list...
React and NestJS Microservices: https://www.youtube.com/playlist?list...
Vue and NestJS Microservices: https://www.youtube.com/playlist?list...