3

If Azure App Service plans are virtual machines dedicated to the Web, API, Logic, and Mobile apps defined within them, does that mean that a web app in an app service plan is an instance of a virtual web server in IIS on that virtual machine?

Assuming this is the case and that each virtual web site gets it's own application pool, is there an Azure scaling strategy or scenario where more than one worker process in that app pool will run, creating a web garden? My understanding of web app scale out is that it results in additional VMs being allocated and not additional worker processes.

Josh
  • 4,009
  • 2
  • 31
  • 46

2 Answers2

1

The scaling strategy will depend upon the pricing tier you have opted for.

Basically each Service Plan will contain a collection of Web, API, Logic, Mobile apps. These will form a web garden within the Service Plan server you choose.

If you initially choose a single B1 Basic Service Plan, you will get a single virtual machine with all of your applications running on that. As the load on that server increases, you can scale it up to larger servers, but it will still be running on a single server.

If you then choose to create a second instance (and a 3rd, 4th, 5th...) that second server will be a replica of the first server, with the load being balanced between the two. (3,4...)

While I've not seen documentation for this, I would imagine that each Web, API, etc app is run under its own application pool / worker process, and scale out is simply duplicated instances.

Michael B
  • 11,887
  • 6
  • 38
  • 74
  • `Basically each Service Plan will contain a collection of Web, API, Logic, Mobile apps. These will form a web garden within the Service Plan server you choose.` Is this a claim that all apps (web, api, logic, mobile) that are created in a Service Plan are actually application instances under the Default Web Site with different app pools? "Web Garden" has a very specific meaning within IIS, and that is what I was driving after. My gut tells me they use virtual web servers with single instance app pools for each App deployed in the App Service Plan, but I'm looking for official validation. – Josh Sep 05 '15 at 19:00
  • It certainly isn't an official answer, merely supposition from how I've seen it working. But I wouldn't imagine it would be difficult to test for the existence of web gardens, you could create an application that intentionally tested session data / Appdomains to understand what knew about what. Is there a specific issue you're experiencing that you believe this to be the problem for? – Michael B Sep 05 '15 at 23:34
1

I'm not sure what a Virtual Server is, but each app runs in its own dedicated application pool and w3wp.exe process. There is only a single w3wp.exe process per application pool, so no web gardens.

Is there a specific reason you think you need these to scale your apps? In most cases, using web gardens is the wrong way to scale, as adding more processes can cause unnecessary overhead (amongst other problems - you can find some useful resources on the web). You almost always want to prefer threads over processes for improving concurrency. If you're running out of physical resources (CPU, memory, etc), then the correct way to scale is to add additional VMs.

Chris Gillum
  • 14,526
  • 5
  • 48
  • 61
  • If you look @ advanced settings for an App Pool, you will see Max Worker Processes which defaults to 1. If you increase that number you will get additional w3wp.exe processes serving that pool and the applications that use it. This is known as a web garden. I'm interested in this not because I'm looking for a validation of a scaling solution, but rather I'm interested in how Azure scale out works and if web gardens are part of the strategy. BTW - a virtual server is what you get when you right click in IIS Manager and choose Add Website. – Josh Sep 08 '15 at 18:20
  • Yes, I'm familiar with the web garden concept in IIS. What I'm trying to say is that it's not supported for Web Apps. The scaling strategy for web apps at the host level is to increase the number of VMs your app runs on. – Chris Gillum Sep 10 '15 at 20:16