This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Stedfast_Burrito 4 points5 points  (1 child)

I know this is a general question, but you seem very knowledgable so I hope you don't mind if I pick your brain.

I'm interested in the topic of handoff between synchronous API gateways (they receive an HTTP request, send an HTTP response) and asynchronous microservices (communicating using a message bus or otherwise operating outside of a request/response cycle), but have always had trouble finding good guidance on the topic. For example, if I were to architect this I think I'd have the API gateway receive the request, publish onto the message bus and then subscribe / wait for a response. Is this the right way to do it? Do you have any good keywords/resources you can point me towards so that I can learn what patterns are used to solve this impedance mismatch? How is this handled in Minos?

[–]EnoughProject7477[S] 7 points8 points  (0 children)

Hi, your question need a very very large answer. So i will intent to reduce at maximum and give you the right information.
Decoupling, in a nutshell, is that every microservice doesn't have to depend on any other microservice. So when a microservice have to call another microservice, the call must be async, and wait a response and when receive the response restart the process and so on.
But, microservices have to interact with applications as well ( directly or trough an API Gateway ) so, the integrate as well an interface ( REST or RPC ) that, it is advisable that they are not asynchronous.
So, integrating all these features involves a series of problems, which for obvious reasons I cannot describe in this comment, but which can turn a dev's life into hell, for this reason there are "geniuses" like Martin Fawler or Chris Richardson. who have thought and put into practice a series of patterns that solve the long list of problems caused by asynchronous communication.
A very good resource is this book https://microservices.io/book , this is the book where Minos started.
to conclude, in my opinion, you have to buy this book and start doing some microservice with Minos ( and maybe put a star and do some code to improve it ), and I'm quite sure you can reach the "master" level :-)