× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Caching makes the most sense when the data comes from a file....

Reduces the number of I/Os your code needs to perform...

I usually store a time-stamp of when the data was retrieved, after a
set period of say 15 seconds, I'll re-retrieve the data.

This allows for single purpose procedures Customer_isValid(),
Customer_GetName()...without an I/O penalty.

Sure, the data could be stale, but no worse than an old school
monolithic program that read the record at the beginning of the
program without a lock and used the data throughout the program.

Charles

On Fri, Jul 1, 2011 at 10:25 AM, James Horn <jdhorn@xxxxxxxxxxxxxx> wrote:
Hi Pete

The caching seems a little scary to me.  I assume you don't do it if the
method gets data from a file (or whatever) which could change between the
calls.

Jim



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.