Microservices Contracts: REST vs Native
This is not a new discussion is very old. I remember back into the SOA days - always was something like REST VS SOAP. SOAP is dead and REST own but now is something different. To be clear - I think REST is the only thing you should use when we talk about External consumers. Like and external API thats would be accessed by a mobile or website. There are other scenarios like INTERNAL consumers. For this case you can consider using a NATIVE driver instead of REST. So whats is a NATIVE driver? Is just code into a language you are using - so could be Java, Scala, Clojure, Ruby, Go, whatever it does not matter. This idea is similar to the JDBC java driver you have java code to access the database. So thats the real question when i have internal consumers for my microservices, should they talk to each other tought REST or native driver? It really depends because both approach have PROS and CONS like everything in life - there are trade offs - but i consider REST in general a ...