Understanding the actor model for distributed systems
In this section, we will learn about the motivation behind the building of Microsoft Orleans and the different trade-offs that Microsoft Research took in defining its features.
In a traditional three-tier system, shown in the following figure, we will have a stateless presentation tier and a stateless middle tier or service layer (business tier). The storage layer (or the third tier) presents a bottleneck for scalability. In this system, the services can be scaled horizontally, so there is a possibility that several clients will attempt to access shared resources concurrently, for example, a record in a database table. In Chapter 1, An Introduction to Distributed Applications, we saw that we can scale the database horizontally too. With the horizontal scaling of databases, we need to deal with the challenges of maintaining data consistency across data centers. Pessimistic locking is an approach we can take to ensure data consistency...