From: James Edward Gray II Date: 2006-02-02T01:09:58+09:00 Subject: Re: memoize to a file On Feb 1, 2006, at 9:56 AM, ara.t.howard@noaa.gov wrote: > On Thu, 2 Feb 2006, James Edward Gray II wrote: > >> On Feb 1, 2006, at 9:31 AM, ara.t.howard@noaa.gov wrote: >> >>> why not pstore - it's done all that already and is built-in? >> >> PStore is just a wrapper on top of Marshal for transactional file >> storage. If you need transactions, it's great. Otherwise, you >> might as well just use Marshal. > > it's not quite only that. it also > > - does some simple checks when creating the file (readability, etc) > - allows db usage to be multi-processed > - supports deletion > - rolls backs writes on exceptions / commits using ensure to > avoid corrupt > data file > - handles read vs write actions using shared/excl locks to boost > concurrency > - uses md5 check to avoid un-needed writes > - opens in correct modes for all platforms These are all great points. Thanks for the lesson. ;) James Edward Gray II