473,394 Members | 1,203 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Cache, Session, ViewState and Application

My question is to do with scalability and the location for storate of cache,
session, viewstate and application data.

Application - Data is stored in memory (in process)
Session - Data is stored in memory (in process or out of process)
- can be configured to store the session data in sql server (which relates
to my question)
ViewState - Page (but can be modified to overwrite the storage mechanism to
store viewstate else where, esp Sesssion)
Cache - Data is stored in memory (in process)
Considering the above (if i'm not wrong), storing data in session state in
web farms with the session data stored in sql server is the best and right
option.
So that if the first request is processed by computer A, and some data is
set in the session, then if the next request by the same user is processed
by computer b the session info will be available (as its stored in sql
server).

What about if information is stored in the cache???
I.e. if in the first request the page stores some info in the cache
(computer A), and the next request is processed by computer B, then WOULD
the cache information be available????

Where is the cache data stored??
In process or out of process??
Can this storage location be configured?
Jul 5 '06 #1
2 1916
You could also consider storing (small amounts of) data in cookies. The
cookies are stored in the browser, and are sent along in every request.

The cache is stored in-process. AFAIK it cant be stored anywhere else.

If you for instance stored a database result in the cache, and the cache
would be stored in the database, that would be rather useless, right?

LeAnne wrote:
My question is to do with scalability and the location for storate of cache,
session, viewstate and application data.

Application - Data is stored in memory (in process)
Session - Data is stored in memory (in process or out of process)
- can be configured to store the session data in sql server (which relates
to my question)
ViewState - Page (but can be modified to overwrite the storage mechanism to
store viewstate else where, esp Sesssion)
Cache - Data is stored in memory (in process)
Considering the above (if i'm not wrong), storing data in session state in
web farms with the session data stored in sql server is the best and right
option.
So that if the first request is processed by computer A, and some data is
set in the session, then if the next request by the same user is processed
by computer b the session info will be available (as its stored in sql
server).

What about if information is stored in the cache???
I.e. if in the first request the page stores some info in the cache
(computer A), and the next request is processed by computer B, then WOULD
the cache information be available????

Where is the cache data stored??
In process or out of process??
Can this storage location be configured?
Jul 5 '06 #2
>Considering the above (if i'm not wrong), storing data in session state in
>web farms with the session data stored in sql server is the best and right
option.
I am no fan of these blanket statements. Stateserver does outperform sql
server for session storage all things considered so sql server is not always
the best and right option

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Göran Andersson" <gu***@guffa.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
You could also consider storing (small amounts of) data in cookies. The
cookies are stored in the browser, and are sent along in every request.

The cache is stored in-process. AFAIK it cant be stored anywhere else.

If you for instance stored a database result in the cache, and the cache
would be stored in the database, that would be rather useless, right?

LeAnne wrote:
>My question is to do with scalability and the location for storate of
cache, session, viewstate and application data.

Application - Data is stored in memory (in process)
Session - Data is stored in memory (in process or out of process)
- can be configured to store the session data in sql server (which
relates to my question)
ViewState - Page (but can be modified to overwrite the storage mechanism
to store viewstate else where, esp Sesssion)
Cache - Data is stored in memory (in process)
Considering the above (if i'm not wrong), storing data in session state
in web farms with the session data stored in sql server is the best and
right option.
So that if the first request is processed by computer A, and some data is
set in the session, then if the next request by the same user is
processed by computer b the session info will be available (as its stored
in sql server).

What about if information is stored in the cache???
I.e. if in the first request the page stores some info in the cache
(computer A), and the next request is processed by computer B, then WOULD
the cache information be available????

Where is the cache data stored??
In process or out of process??
Can this storage location be configured?

Jul 6 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Arthur Dzhelali | last post by:
Is there any way to cache dataset on one page and it will be accessible for one user? if you declare dataset shared it will stay on the server and page will be able reference to it on reload,...
7
by: Mike | last post by:
Hi, I have an ASP.NET solution in which I need to store some information, such as DB user and password. So far, I have used the Context object to share information between the various pages, but I...
3
by: Alex Nitulescu | last post by:
Sorry, I'm really confused - I'm only at the middle of my book and already I can count 4 methods to store values. Yes, I know that cookies can not store much, but what is the difference between...
3
by: MattC | last post by:
Hi, I am persisting the viewstate for each page into the Cache object, below is shown my methods for saving and loading: I am able to save the viewstate to the cache and most times I can load...
2
by: Kikoz | last post by:
Hi all. I keep my ViewState in server's cache. Works fine except when user leaves the page opened for a long time (2 hours or so). Then if he/she tries to post it back the server throws an...
4
by: INeedADip | last post by:
Can I put a generic List<MyObject> in cache? I read that generics can't be serialized.. Can I cache them? Can I return them from Web Services?
3
by: Dragon | last post by:
Session ViewState Cache Already There are Session and ViewState What is the use of Cache ?
5
by: Prashanth | last post by:
Hi, I want to cache an object whose scope in only within the page. The cache should expire once the user leaves the page. How can I do it? Regards, Prashanth
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.