Hi guys
I have a project i created with two big monoliths , one serving as an api server for my main website, and the second one for the admin website.
For several reasons ive decided to break those two monoliths in to microservices architecture.
From my understanding the best practice is using the nestjs/microservices library and currently for simplicity ive decided to use TCP as the transport protocol between the microservices.
I understand that i need to add another nestjs application that will serve as an api gateway (receiving http requests and acting as a proxy to the specific microservice through TCP).
What i wanted to know is what are some best practices and recommendations for all this process.
Should the api gw validate the jwt tokens kr each microservice?
where should i use the cache layer?
Should i use curcuit breaker?
I will also add that i have another different service which consumes jobs from bullmq, but this is not really relevant.
I would like to get some dos and donts as i want to be able to handle high scales (talking about thousands of users), and if im doing something wrong i would like to learn😇
Thanks in advance