Cache or Application variable

M

Martin

Hi,

I have been trying to find a good article that would explain the scalability
of the cache and application variables accross a web farm.

I believe that application variables will not scale accross a web farm,
however I am undecieded about settings stored in the cache.

If anybody can shed any light on this for me or point me in the direction of
good articles on the subject then it would help mr a great deal.

many thanks in advance.

martin.
 
J

Janaka

Martin,

Both the Cache and Application variables store data in the same way, in
local memory on the server. This proves to be much more scalable than
repeatedly making calls to say a database or flat file to retrieve
information. Unlike Sessions there's no special way you need to set these
variables. As long as you code in a logical manner each server in your web
farm should have its own local copy of Application/Cache data.
I prefer using the Cache because it cleans up the memory after a period of
time you specify and you can attach dependancies on your data as well.

Janaka
 
K

Kevin Spencer

Cache is also known as "Application Cache," as its memory space is part of
the Application memory space, and it is gloabal to the Application. So, no,
neither Application, nor any other memory-based caching mechanism will cross
application boundaries across a Web Farm.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living
 

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,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top