Scaling with Azure Web Sites

Topics: Administration, Installing Orchard
Sep 25, 2012 at 10:27 AM


I am currently experimenting with installing Orchard on Azure using the recently released "Web Sites" functionality.

I have successfully installed and setup Orchard using the template from the gallery and so far everything seems to be going well.

My question is: If I scale up the site to use 3 instances is there anything special I need to do to ensure that the instances all work from the same cache? So a new page appears on all instances at once.

I have a little experience with Umbraco and I had to push documents and the cache into blob storage for it to work correctly.

Is this already taken care of by the template?

Thanks for your help, 


Sep 25, 2012 at 4:53 PM
Edited Sep 25, 2012 at 4:53 PM

You would need some form of distributed cache module, which doesn't come out of the box with Orchard.

Sep 25, 2012 at 5:26 PM

Thanks for your reply, I'll have a look into using the distributed cache in Azure.

On another forum someone has suggested using the sites.config to enable BlobStorage, do you think this would work also, or is this just for uploaded media?

Sep 25, 2012 at 6:04 PM

Oh, sure, blob storage come standard, but that's not going to help with the caching, only with media storage.

Sep 25, 2012 at 6:33 PM

Nicholas has created an Azure appFabric distributed cache module:

I haven't tried this yet. Contact Nick to find the status on how stable it is, if/how many are using it in production.

Sep 25, 2012 at 7:15 PM

You need to use BlobStorage to scale AWS sites too? That adds some complexity. Also maybe for a project of mine App_Data would need to be shared as well, not just Media.

BTW slightly offtopic, but has anybody tried SQL Azure with Orchard (on AWS)? By default there's only MySQL for AWS sites.

Sep 25, 2012 at 11:15 PM

Ok great so I need to setup blob storage for the media, use a distributed cache for the caching (thanks for the link Monarch) is there anything else I would need to do to get it working correctly in a multi-instance environment?

Would I need to create a session provider to use distributed cache as well?

Thanks for all your help,

Sep 25, 2012 at 11:20 PM

@Piedone: no, app_data should not be shared. There is no reason why SQL Azure wouldn't work. Just provide the connection string. Maybe your subscription doesn't have SQL Azure?

Sep 26, 2012 at 3:45 PM

I haven't tried SQL Azure, currently I'm just evaluating AWS and gathering information. It's just that per default there's only a MySQL DB included in an AWS subscription.

For a project I'd need at least partial App_Data sharing, or replicating, because there's a need to be able to create tenants live.

Sep 26, 2012 at 4:15 PM

Piedone, are you saying you want to run the web part on AWS, and have them rely on SQL Azure for database? Are you worried it might introduce high latency, having to go across separate datacenters? You could mitigate by having caching; not sure if there is a cache module already built for AWS. 

Sep 26, 2012 at 4:28 PM

I not necessarily "want", but rather I'm now seeking options to run a website with a bigger DB than the included 20MB MySQL. Not having used Azure, I think if you opt with a data center your DBs will be created also there, or you have an option to locate it there, not right?

Sep 26, 2012 at 5:02 PM

Ah, OK. I misunderstood. I thought you wanted to mix AWS Web with Azure DB.