re: Microservices communications. Why you should switch to message queues. VIEW POST

VIEW PARENT COMMENT VIEW FULL DISCUSSION
 

In order:

  • CORS don't apply here since we are not in a browser. We are talking about microservices talking to each other.
  • there are many ways to authenticate microservices with each other. Tokens are one way, however since we have a middleman between services (the message broker) which already requires them to authenticate, you can trust messages you receive (to some degrees).
  • what does 2FA even have to do with microservices? We are not talking about users authenticating with an application, this article is about inter-service communications.
  • REST is NOT async, as it's just a pattern built on top of HTTP which is synchronous (you open a connection, you send a request, you wait for a response, you close the connection). The fact that languages like JavaScript allow you to perform request asynchronously doesn't mean that the protocol itself is asynchronous. Otherwise everything could be considered async.

If you have specific points you wanna discuss, possibly with some real arguments to back them up, I'd be more than happy to do so. Otherwise please refrain from submitting such pointless comments again.

 

I was just throwing CORS, 2FA out as examples. API's use LOTS of security and authorization. And that is implemented on the backend.

If you are saying AMQP is better than HTTP then you are saying it is a replacement for HTTP based API's.

So, how are you going to implement alot of the protocols that you will need to implement LIKE CORS, 2FA, Authorization? :)

Fill in the gaps that you want to replace. Thats a huge gap you don't have solutions for.

... and yes, REST API's can be async. Check it out sometime.

I already answered to all of you points and I'm starting to believe you are not interested in having a fair, healthy discussion but to just start some flame.
As I already stated, this article is about inter-service communications, not public facing APIs to be consumed by a user. So you don't have CORS, you don't have 2FA and you don't need microservices to authenticate with each other directly because this stuff simply doesn't apply in this context.
I really don't see where you're going with this discussion.

And again no, REST is not async on its own as I already said. You can use asynchronously, you can do funny stuff with webhooks and Websockets to make it behave like an async process, but REST itself does not provide any primitive for async message passing. And just saying "check it out sometime" without actually explaining your self or linking some resources says a lot about your way of managing discussions.
Now if you have some actual constructive feedback to give please be my guest, otherwise I will not continue with this pointless conversation

You haven't answered anything. You dodge. You merely state 'this is not an api' but neglect to answer how AMQO provides equivalent services to what HTTP provides

code of conduct - report abuse