Why can't Application state be managed like Session state?

G

Guest

Session state has options to be inproc, state server or sql server. Why does
Application state not allow for state server or sql server so the same
Application state could be shared between servers in a farm?
 
P

Patrice

Application state is rather considered as local and IMO the interest of
doing this would really depend on what you store.

What read/write value would you like to share accross the farm ?
 
A

Alvin Bruney - ASP.NET MVP

application state applies to the process not the machine, if you want a
global store you should consider using a database or a third party product
or file across webfarms

--
Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ www.lulu.com/owc
Forth-coming VSTO.NET - Wrox/Wiley 2006
 
B

Bruce Barker

session state only allows one request at a time (across the farm if out of
proc), this prevents several issues with consistency. this would be a real
performance problem with application state (only 1 request at time across
the farm).

..net 2.0 (with sql2005) allows you cache an object and use a sqlserver
dependency, to be notified of a change, but no consistency is guaranteed.

-- bruce (sqlwork.com)
 
G

Guest

I was mainly asking to see if MS did not allow for sharing Application state
for a web application in a web farm because of a technical reason or a design
reason. Since Session state can be shared across a web farm, why not
Application state?

One reason I could see is the problem with locking Application property bags
across machines. Just wanted to know if anyone was aware of specific reasons
from ASP.Net devs.


Thanks
 
S

Steven Cheng[MSFT]

Hi Joac,

AS for the ASP.NET's HttpApplicationState, actually it's existing for
backward compatiblity to classic ASP's applicaitonState. There it no plan
to design it for cross application(cross appdomain) usage. For Application
wide usage, what ApplicationState can do can also be done through ASP.NET
applcation Cache. And Cache provide further advanced expiring and
dependency support. Also, since application state is application instance
specific, after applicaiton restart or process recycle, they'll no longer
be kept...

As for SessionState, since it is associated with a certain clientside
browser connection ,so it's important and necessary to provide external
persistence store for SessionState datas so as to keep them between
application restart or server process recycle.

Currently , for using ASP.NET in webfarm/ webgarden scenario, the State
management is really a critical point we need to consider since there is no
build-in external Application State persistence mechanism in ASP.NET.

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)



--------------------
| Thread-Topic: Why can't Application state be managed like Session state?
| thread-index: AcXj0c1EZ76Po+YZQ0y6j7HAAAwY2g==
| X-WBNR-Posting-Host: 216.201.157.114
| From: "=?Utf-8?B?RXJpYyBNY1ZpY2tlcg==?=" <[email protected]>
| References: <[email protected]>
<#[email protected]>
| Subject: Re: Why can't Application state be managed like Session state?
| Date: Mon, 7 Nov 2005 11:31:08 -0800
| Lines: 12
| Message-ID: <[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet:136708
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| I was mainly asking to see if MS did not allow for sharing Application
state
| for a web application in a web farm because of a technical reason or a
design
| reason. Since Session state can be shared across a web farm, why not
| Application state?
|
| One reason I could see is the problem with locking Application property
bags
| across machines. Just wanted to know if anyone was aware of specific
reasons
| from ASP.Net devs.
|
|
| Thanks
|
|
 
S

Steven Cheng[MSFT]

Hi Joac,

Have you got any further ideas on this question? If there're anything else
we can help, please feel free to post here.

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| X-Tomcat-ID: 60528286
| References: <[email protected]>
<#[email protected]>
<[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: (e-mail address removed) (Steven Cheng[MSFT])
| Organization: Microsoft
| Date: Tue, 08 Nov 2005 03:01:14 GMT
| Subject: Re: Why can't Application state be managed like Session state?
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| Lines: 72
| Path: TK2MSFTNGXA01.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet:136813
| NNTP-Posting-Host: TOMCATIMPORT1 10.201.218.122
|
| Hi Joac,
|
| AS for the ASP.NET's HttpApplicationState, actually it's existing for
| backward compatiblity to classic ASP's applicaitonState. There it no plan
| to design it for cross application(cross appdomain) usage. For
Application
| wide usage, what ApplicationState can do can also be done through ASP.NET
| applcation Cache. And Cache provide further advanced expiring and
| dependency support. Also, since application state is application
instance
| specific, after applicaiton restart or process recycle, they'll no longer
| be kept...
|
| As for SessionState, since it is associated with a certain clientside
| browser connection ,so it's important and necessary to provide external
| persistence store for SessionState datas so as to keep them between
| application restart or server process recycle.
|
| Currently , for using ASP.NET in webfarm/ webgarden scenario, the State
| management is really a critical point we need to consider since there is
no
| build-in external Application State persistence mechanism in ASP.NET.
|
| Thanks,
|
| Steven Cheng
| Microsoft Online Support
|
| Get Secure! www.microsoft.com/security
| (This posting is provided "AS IS", with no warranties, and confers no
| rights.)
|
|
|
| --------------------
| | Thread-Topic: Why can't Application state be managed like Session state?
| | thread-index: AcXj0c1EZ76Po+YZQ0y6j7HAAAwY2g==
| | X-WBNR-Posting-Host: 216.201.157.114
| | From: "=?Utf-8?B?RXJpYyBNY1ZpY2tlcg==?=" <[email protected]>
| | References: <[email protected]>
| <#[email protected]>
| | Subject: Re: Why can't Application state be managed like Session state?
| | Date: Mon, 7 Nov 2005 11:31:08 -0800
| | Lines: 12
| | Message-ID: <[email protected]>
| | MIME-Version: 1.0
| | Content-Type: text/plain;
| | charset="Utf-8"
| | Content-Transfer-Encoding: 7bit
| | X-Newsreader: Microsoft CDO for Windows 2000
| | Content-Class: urn:content-classes:message
| | Importance: normal
| | Priority: normal
| | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| | Newsgroups: microsoft.public.dotnet.framework.aspnet
| | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| | Xref: TK2MSFTNGXA01.phx.gbl
| microsoft.public.dotnet.framework.aspnet:136708
| | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
| |
| | I was mainly asking to see if MS did not allow for sharing Application
| state
| | for a web application in a web farm because of a technical reason or a
| design
| | reason. Since Session state can be shared across a web farm, why not
| | Application state?
| |
| | One reason I could see is the problem with locking Application property
| bags
| | across machines. Just wanted to know if anyone was aware of specific
| reasons
| | from ASP.Net devs.
| |
| |
| | Thanks
| |
| |
|
|
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top