List Info

Thread: Caching data within session allowing for cache dependencies?




Caching data within session allowing for cache dependencies?
user name
2006-05-20 05:21:03
> I have a requirement whereby I need to store data
within Session however I
> need to associate the data with a key if the key
changes I need the data to
> be removed. In essence I need to use cache with cache
key dependencies but
> the storage must be Session.

You can store the value in Session based on a key string...
then place
the key string in Cache with the appropriate dependancy. 
Next, make
sure that you occasionally foreach scan through the Session
looking
for key strings that are not in the Cache...

> How this would work (if at all across) across a web
farm I haven't even
> started about that. Anybody got any suggestions?

If you need cached values across a web farm, DON'T waste
your time
reinventing nCache.... just buy it from Alachisoft.  It's
an awesome
product.

http://www.alach
isoft.com/index.html

If you can't use that product, then what you need to do is
setup your
dependancies in the shared-database for the ASP.Net Session
and use
cascaded deletes to manage things... there be dragons...
tread
carefully.

-- 
"Remember when you are juggling all those balls that
some of them are
glass balls, some of them are rubber balls. Don't drop the
glass
ones."  - Nora Roberts

Marc C. Brooks
http://musingmarc.blog
spot.com

===================================
This list is hosted by DevelopMentorŪ  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

Caching data within session allowing for cache dependencies?
user name
2006-05-22 15:27:24
> If you need cached values across a web farm, DON'T
waste your time
> reinventing nCache.... just buy it from Alachisoft. 
It's an awesome
> product.
>

Hi Marc,

Is it really an awesome product?

We are looking for a distributed cache between 10 servers
for a site
with a very high traffic.

// Ryan

===================================
This list is hosted by DevelopMentorŪ  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

Caching data within session allowing for cache dependencies?
user name
2006-05-22 15:57:59
> > If you need cached values across a web farm,
DON'T waste your time
> > reinventing nCache.... just buy it from
Alachisoft.  It's an awesome
> > product.
>
> Is it really an awesome product?

I beat the heck out of it during the beta for my own
personal use...
it does exactly what it says it does.  The programming model
is pretty
good and a look into it with Reflector didn't raise any
red-flags.  My
only concern is that it'll eventually become obsolete when
Microsoft
finally ships something in this space... but for now I
can't find any
better way to do this sort of thing.  Is it better than
stuffing
things in a (really big) SQL Server cluster?  Probably not,
but it
certainly is easier to develop and deploy against! 

> We are looking for a distributed cache between 10
servers for a site
> with a very high traffic.

Honestly, I would make darn sure that you need a distributed
cache, by
gathering hard statistics to see where your hotspots are,
first.  But
if you know that you've optimized your UI, BL and DAL code,
and that
your queries are quick enough, then this is a great product.

-- 
"Remember when you are juggling all those balls that
some of them are
glass balls, some of them are rubber balls. Don't drop the
glass
ones."  - Nora Roberts

Marc C. Brooks
http://musingmarc.blog
spot.com

===================================
This list is hosted by DevelopMentorŪ  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )