Abstract

Microservice architectures (MSA) are becoming a preferred architectural style for data-driven applications. A transaction within MSA can include remote calls to multiple services, turning it into a distributed transaction. Participating services may have their own data stores running local transactions with varying levels of transactional support and consistency guarantees. Coordinating distributed transactions in such an environment is a key challenge for MSA. The existing approaches are either highly consistent at the expense of scalability or scalable at the expense of consistency. Furthermore, implementing any of them requires architectural and code adaptation. In this article, we present the Service Proxy Transaction Management (SPTM) approach, which offers scalable reads and ACID transactions in MSA. The novelty of this approach is that it is based on intercepting inbound messages to services, rather than having services directly communicate with a transaction manager. As a result, transaction management is completely transparent to services and has little-to-no impact on code or architecture. We provide experimental results showing that SPTM can outperform lock-based approaches by up to a factor of 2, while still providing high consistency without the scaling bottleneck associated with locking.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call