Hacker News new | past | comments | ask | show | jobs | submit login

Sure, it's possible/reasonable to do both. I work with asynchronous Microservices using RabbitMQ where PubSub shines in that many services can respond when the application publishes a message (1 service for email, 1 for push notifications, 1 for capturing data for analytics, etc). But it is fire and forget as far as the application is concerned.

Compare that to synchronous services where the application has be aware of all of them and coordinate calling them all. It is easier to use synchronous when the application requires an output from the service to respond.

Transactions across services are certainly not easy:

"Distributed transactions are notoriously difficult to implement and and as a consequence microservice architectures emphasize transactionless coordination between services, with explicit recognition that consistency may only be eventual consistency and problems are dealt with by compensating operations." [1]

[1] http://martinfowler.com/articles/microservices.html




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: