Re: [need for advices] fastCaching
| From: | Brent Cook | Date: | Mon, 22 Jul 2002 18:31:11 +0000 |
| Subject: | Re: [need for advices] fastCaching | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-7874@lists.php.net to get a copy of this message | ||
On Mon, 22 Jul 2002 fabien.marty@free.fr wrote:
> > A quick review of the code shows no handling of corrupt cache files.
> > I suggest writing the file length into the cache file and some
> > signature
> > bytes
> > as a prefix/suffix to the cache data to ensure data integrity.
>
> With FileLocking on (default), it's very very difficult to have
> corrupted cache files. But adding a test is possible. A md5 hash would
> be perfect but we would have to do some benchs. Because adding only file
> length has to be faster I think.
>
> Fabien
I've had instances of corrupt cache on Digital Unix using NFS pretty
often (mostly empty files), so this is important, though it could be
optional.
- Brent