“Web garden” scaling out by increasing the number of worker processes per CPU. Web gardening will allow more than two subscribers to synchronize at the same time. Before going to the details of web garden, I hope you have fundamental idea on application pool and worker process. Just for reminder – for request processing in IIS, worker process (w3wp.exe) runs the ASP.NET application in IIS. Worker process is responsible for handling all kinds of request, response, session data, and cache data. Application Pool is the container of worker process. Application pool is used to separate sets of IIS worker processes and enables a better security, reliability, and availability for any web application. It will also increase CPU utilization by replisapi.dll, which can negatively impact overall server performance. So, it is important to balance these considerations when you choose a value for Maximum Worker Processes.
Fig – Application pool is the container of one or more worker processes
Now, by default, each and every Application pool contains a single worker process. Application which contains the multiple worker process is called “Web Garden”. Below is the typical diagram for a web garden application.
Fig – Multiple worker process in an application pool (Web garden)
Why Web garden?
- Offering applications that are not CPU-bound but execute long running requests the ability to scale and not use up all threads available in the worker process
- Applications that make long running database requests (e.g. high computational database transaction)
- Applications that have threads occupied by long-running synchronous and network intensive transactions
- You can support a greater number of concurrent synchronization operations per CPU by increasing the Maximum Worker Process property value
- Provides better application availability by sharing request between multiple worker processes.
- Web garden use processor affinity where application can swapped out based on preference and tag setting.
- Less consumption of physical space for web garden configuration.