Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Windows Azure & ASP.NET session

I have ASP.NET web application which stores information on the session while user goes through pages. Will I have any problems if I deploy such application to Windows Azure?

like image 839
Andrew Bezzub Avatar asked Oct 24 '10 17:10

Andrew Bezzub


People also ask

What does Microsoft Azure do?

Microsoft Azure (formerly Windows Azure /ˈæʒər/) is a cloud computing service created by Microsoft for building, testing, deploying, and managing applications and services through Microsoft-managed data centers.

What is the official website of Microsoft Azure?

Website. azure .microsoft .com. Microsoft Azure, commonly referred to as Azure ( / ˈæʒər / ), is a cloud computing service created by Microsoft for building, testing, deploying, and managing applications and services through Microsoft-managed data centers.

What is the full form of azure?

azure .microsoft .com. Microsoft Azure, commonly referred to as Azure ( / ˈæʒər / ), is a cloud computing service created by Microsoft for building, testing, deploying, and managing applications and services through Microsoft-managed data centers.

What is Azure cloud computing?

Microsoft Azure, commonly referred to as Azure ( / ˈæʒər / ), is a cloud computing service created by Microsoft for building, testing, deploying, and managing applications and services through Microsoft-managed data centers. It provides software as a service (SaaS), platform as a service (PaaS) and infrastructure as a service (IaaS) ...


2 Answers

As Nariman stated, you can't have server affinity - the load balancing is beyond your control. You can use either table storage or SQL Azure for session state. I don't really see much value in storing session state in blobs.

See this post on the SQL Azure blog, from August 2010, to see how to implement session storage in SQL Azure. This will allow you to manage session state across instances as you scale up.

EDIT 6/16/2014 - The Redis cache supports this. See Azure Redis Cache (Preview) ASP.NET Session State Provider

EDIT 5/23/2012 - Wow, lots has changed since I posted this. SQL Azure is fully supported as a session state provider (via Universal Providers, shipping since v1.4), as well as Windows Azure Cache. More details are provided in this StackOverflow answer.

like image 100
David Makogon Avatar answered Sep 19 '22 12:09

David Makogon


You won't notice a difference on a single-instance deployment that uses InProc but you do need to rely on out of process Blob & Table storage if you plan on running multiple web roles. (There's no way to keep a user pegged to the same instance in Azure load-balancing, AFAIK.)

like image 23
Nariman Avatar answered Sep 21 '22 12:09

Nariman