Answered by:
Design Web Role for Multiple Instance to Scale out

Question
-
I am designing an application which would be a web api providing some read only data to its consumers.
The data that web role work on , should come from Worker Roles. Since there could be multiple web roles that wud response to customer HTTP request. What is the best way to ensure that the data is in sync.
I thot of doing it in this way. The data is processed by worker roles and then merged and synced in redis cache.
Web Roles mearly read it. Do you suggest there could be better ways to do it.
Vineet
Thursday, July 30, 2015 12:21 AM
Answers
-
Hi,
Based on your scenario, the recommended approach I would say is to use Redis Cache.
Microsoft Azure Redis Cache is based on the popular open source Redis Cache. It gives you access to a secure, dedicated Redis cache, managed by Microsoft, providing the best of both worlds: the rich features and ecosystem of Redis, and reliable hosting and monitoring by Microsoft.
You can learn more at the below site.
https://msdn.microsoft.com/en-us/library/dn690523.aspx
http://www.asp.net/aspnet/overview/developing-apps-with-windows-azure/building-real-world-cloud-apps-with-windows-azure/distributed-cachingRegards,
Nithin Rathnakar- Proposed as answer by Nithin.Rathnakar Sunday, August 2, 2015 12:10 PM
- Marked as answer by Nithin.Rathnakar Monday, August 3, 2015 1:38 PM
Thursday, July 30, 2015 4:12 PM
All replies
-
Hi,
Can you try the suggestions from the below blog and check if it helps.
https://azure.microsoft.com/en-in/documentation/articles/cloud-services-how-to-scale/
Regards,
Thursday, July 30, 2015 6:43 AM -
Hi,
Based on your scenario, the recommended approach I would say is to use Redis Cache.
Microsoft Azure Redis Cache is based on the popular open source Redis Cache. It gives you access to a secure, dedicated Redis cache, managed by Microsoft, providing the best of both worlds: the rich features and ecosystem of Redis, and reliable hosting and monitoring by Microsoft.
You can learn more at the below site.
https://msdn.microsoft.com/en-us/library/dn690523.aspx
http://www.asp.net/aspnet/overview/developing-apps-with-windows-azure/building-real-world-cloud-apps-with-windows-azure/distributed-cachingRegards,
Nithin Rathnakar- Proposed as answer by Nithin.Rathnakar Sunday, August 2, 2015 12:10 PM
- Marked as answer by Nithin.Rathnakar Monday, August 3, 2015 1:38 PM
Thursday, July 30, 2015 4:12 PM -
Hi Vineet
Yes, you are correct. It doesn't matter how many web role are serving the request as long as they all are reading data from same source.
You can use Redis Cache or a cheaper version would be Azure Storage. Also, not sure what job your worker roles are doing but a Web Job is as good and cheaper.
Regards
Piyush
Piyush Gupta
- Proposed as answer by Nithin.Rathnakar Sunday, August 2, 2015 12:10 PM
Thursday, July 30, 2015 9:05 PM