Stateless frontend and stateful middle-tier

In this model, you build stateless web apps such as ASP.NET and Node.js and deploy your application's frontend as stateless Reliable Services. The model can be seen in the following image:

Stateless front-end and stateful middle-tier

The Front End can communicate with Stateful Middle-tier Compute using queues, in case asynchronous processing is desired, or using HTTP protocol, in case synchronous communication is desired. This model delivers better performance because the state lives near the compute, which avoids network hops. This model also helps ensure data consistency using transactions to commit data in data stores. In this model, the middle-tier can be built using stateless web framework such as Web API or it can execute as a continuously executing process.

You might have noticed that in both the models we have used a load balancer to route traffic to appropriate stateless service that hosts the frontend of our application. That is because web browsers don't have the ability to interact with the Naming Service to resolve the endpoint of a healthy instance of the service. When you provision your Service Fabric cluster on Azure, you get the ability to add a load balancer to proxy your instances. The load balancer uses a probe to determine the health of the frontend nodes and routes traffic only to the healthy nodes. Addition of a load balancer also makes the process of scaling of frontend invisible to the clients of your application. The load balancer automatically distributes the incoming traffic to the healthy nodes, thus ensuring that your resources get utilized optimally.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.116.19.17