Application Pool in IIS
An Internet Information Services (IIS) application pool is a set of
URLs that is routed to one or more worker processes. Application pools
responsible for to isolate one or more applications into their own
process. For example you have two different website like website-A and
website-B and want to deploy on same server, then application pool
isolate your website means website-A run on one application pool and
website-B run on another application pool.
It provides a convenient way to administer a set of web sites and
applications and their corresponding worker processes. Process
boundaries separate each worker process; therefore, a web site or
application in one application pool will not be affected by application
issues in other application pools. Application pools significantly
increase both the reliability and manageability of a Web infrastructure.
Create Application Pool in IIS
You can also create your own application pool with custom settings.
Key Points About Application Pool
- Provides isolation between different web applications.
- Every web application has individual worker process.
- Improve manageability of web application.
- Provides better performance.
Configuring the Application Pool
For configuring the application pool, you need to configure the following properties in application pool.
- Recycling
- Performance
- Health
- Identity
Application Pool Recycling
Recycling application pools option is available in IIS6, IIS7.x and
IIS8. This is a process for recycling the work process (w3wp.exe) and
the memory used by the web application. It’s good practice to recycle
the worker process periodically since it keeps application running
smoothly.
IIS 7.5 Setting for Application Pool recycling:
How Recycling Process initiates:
You need not to worry
about the application performance while recycling process. This process
is transparent from client. When IIS conduct recycling, it invokes a new
worker process first, and then shut down the old worker process. In
this way application request will be handle by the new worker process
without downtime. This process is required high-availability of IIS.
Advantages of using IIS recycling feature
- All the clients can connect to IIS server, and every requests will be handled without downtime.
- There is no connection loss.
- It is a faster operation than IISRESET to initialize system resource (memory).
IIS RESET
IIS RESET command stops all IIS services with its components. In
fact, it does not kill any worker processes, and running components.
Like any windows services, the command just sends a message – “Stop
running as soon as possible” – to shutdown IIS services gracefully.
Disadvantage of IIS Reset
- HTTP.SYS will lose existing client-connections after running IISRESET.
- All incoming requests will need to establish new connections again.
- Web browsers can’t connect the IIS server during restarting IIS means all requests will be missed.
- A worker process can’t keep any data – cached objects & binaries
Different Type of Application Pool Available in IIS 7.0 and IIS 7.5
There are two types’ .NET integration modes for ASP.NET application,
that identified that how IIS processes an incoming request to the sites,
applications and web services that run in that application pool.
Integrated Mode
Integrated mode makes ASP.NET an integral
part of IIS. Now the IIS server functionality is split into more than 40
modules that break the IIS and ASP.NET functionality into pieces.
Modules such as StaticFileModule, BasicAuthenticationModule,
FormsAuthentication, Session, Profile and RoleManager are part of the
IIS pipeline. FormsAuthentication, Session, Profile and RoleManager were
previously part of ASP.NET and didn't have anything to do with IIS.
Classic Mode
Classic mode models the IIS 6.0 model in which
ASP.NET is an ISAPI add-on to IIS. This mode is available for backward
compatibility but lacks many of the features in the new integrated mode.
In Classic mode, IIS has its own pipeline that can only be extended by
creating an ISAPI extension, which has a well-deserved reputation for
being difficult to develop. ASP.NET is run as an ISAPI extension that is
just one part of the IIS pipeline.
What do you think?
I hope now you have better understanding about Application Pool in
IIS. Your valuable feedback, question, or comments about this article
are always welcome.