PC Review Forums Newsgroups Microsoft DotNet Microsoft Dot NET Framework In memory data access

Reply

In memory data access

 
Thread Tools Rate Thread
Old 24-02-2005, 02:11 PM   #1
martyn_wynne@hotmail.com
Guest
 
Posts: n/a
Default In memory data access


I have 3 fields, SecurityID (int), Price (decimal) and DateStamp
(DateTime), up until now i've been recording the price in a SQL table
and reading it out. The reading is fine, but the boxes are really
stuggling with the writing, the Avg. Disk Queue Length is bordering on
a bottle neck.

So, i want to have a Windows Service keep this in memory and respond to
remote calls to set and get the data. Persistance is not required.

Now, which form shall i store the info in, DataTable, a collection of
objects, xml, or some other?

I want pure speed in and out.


Thanks in advance.

  Reply With Quote
Old 25-02-2005, 04:11 PM   #2
Pat A
Guest
 
Posts: n/a
Default Re: In memory data access

If you want to maximize speed, use an array of objects. If that's
still not fast enough, you can use unsafe code so the array is not
garbage collected. I think that will give you the maximum possible
performance.

  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off