pan-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Pan-devel] the Article cache [was: Speed of Pan]


From: Duncan
Subject: Re: [Pan-devel] the Article cache [was: Speed of Pan]
Date: Mon, 4 Nov 2002 23:33:05 -0700
User-agent: KMail/1.5

On Monday 04 November 2002 12:10, Jeffrey Stedfast wrote:
> On Mon, 2002-11-04 at 11:49, Charles Kerr wrote:
> >
> > I'm leaning towards keeping a flat file with a list of the message-ids
> > in the cache.  This would replace directory walking with a simple file
> > read. The only downside I see is that people tinkering by hand could get
> > the flat file and the directory contents out of sync.
>
> Yea... I thought of that too. Let me give you some thoughts:
>
> Keep your cache file (I suppose it would contain message-ids) but also
> keep a mtime for the cache directory. If mtime != cache->mtime, then
> re-scan the cache the way you do now. Otherwise you can safely assume
> that the cache hasn't been touched by the user.
>
> This makes it so that if the user doesn't touch his cache, it should be
> extremely fast - otherwise, well... no slower than it is currently :-)

I'd only caution to test for cache file pars-ability, and scan the cache dir 
the long way if unparsable, as well.  It's not just user monkeying I'm 
worried about, but also the occasional instability.  0.13.1 is better with 
that than I've seen in awhile, but there's a lot of new features and possible 
crashes <g> yet to be added.

-- 
Duncan
"They that can give up essential liberty to obtain a little
temporary safety, deserve neither liberty nor safety." --
Benjamin Franklin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]