Caching a Large DataSet

G

Guest

I maintain a list of companies in my application. The first time the company table is accessed, I create a dataset and stick it in the Cache. When the company table is modified, I expire the cached item, recreate the DataSet, and stick it in the Cache again

I get excellent performance when running this on my local machine. I can tell when an aspx is accessing a cached copy of the company list since it's very fast. However, it's painfully slow on my production server.

I'm starting to wonder whether it's efficient to store a DataSet that large (1 table, 4000 rows, 5 columns) in the Cache. Should I consider another data type such as an ArrayList that would be lighter to carry around?
 
A

Alvin Bruney [MVP]

That size data is not overly large IMHO and it should not present a problem
normally. What kind of traffic are you seeing which leads to the slowdown?
If you have a large number of concurrent users, then you may feel a pinch
when the cache is accessed to service a request. Outside of that, i'd
probably start looking at some other factors for the slowness.

Alternatively, you may want to try going straight to the database as a
troubleshooting technique to pinpoint the problem. See if that helps any.
--
Regards,
Alvin Bruney [ASP.NET MVP]
Got tidbits? Get it here...
http://tinyurl.com/3he3b
George Durzi said:
I maintain a list of companies in my application. The first time the
company table is accessed, I create a dataset and stick it in the Cache.
When the company table is modified, I expire the cached item, recreate the
DataSet, and stick it in the Cache again.
I get excellent performance when running this on my local machine. I can
tell when an aspx is accessing a cached copy of the company list since it's
very fast. However, it's painfully slow on my production server.
I'm starting to wonder whether it's efficient to store a DataSet that
large (1 table, 4000 rows, 5 columns) in the Cache. Should I consider
another data type such as an ArrayList that would be lighter to carry
around?
 

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

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,175
Latest member
Vinay Kumar_ Nevatia
Top