RESTful communication between microservices can be perfectly fine

Click for: original source

Daniel Westheide article in which he wants to clarify how the terms used should be understood and show that HTTP and REST for internal service communication can be perfectly fine. He also explains that choosing to do so has nothing to do with whether your services integrate synchronously or asynchronously –- and the latter question is what you should really be concerned with.

He argues, that when talking about synchronous versus asynchronous, one needs to consider:

  • Async IO (callbacks, futures, streams)
  • Asynchronous protocols (message passing, request-reply pattern)
  • Asynchronous service integration
  • Self-contained systems

In an ideal world, no communication whatsoever between your microservices should be necessary. And if it has to happen, it should be asynchronous. If you have to call other services in order to be able to serve a response to a request from a public client, this is really an architectural problem.

Author then argues that what you should really care about when designing your services is decoupling in time, which can be achieved or violated with both REST and message passing. Learn more in this interesting article.

[Read More]

Tags microservices software-architecture restful