views:

769

answers:

2

A Session is per browser (determined via cookies), but when does an "Application" start, and end, and how does IIS know know when a request is a part of the same same "Application" instance (if not done via cookies the same way that sessions are)?

+3  A: 

"Application" scope is global, and every request to a website shares the same application. Anything stored in the application is visible to all users. The application starts when the first request to the website is made, and ends when IIS stops the website (for example, when IIS itself is shut down, or when the website hasn't been accessed in a while).

Sean Reilly
+1  A: 

Application is said to be start when it is first deployed on the webserver and is available to the users for access. Each time it is un-deployed or the server is shut down the application ends.

The second part is not clear but assuming for determining the application, each application has a root which is unique for all the application that are deployed on a web /app server. So the server can figure that out from the URL being requested.

As such each request is considered as separate and some mechanism like sessions, cookies etc has to be used to club individual requests as a part of single user session.

Nrj