[ZODB-Dev] blobs missing with relstorage and small blob cache dir
Maurits van Rees
m.van.rees at zestsoftware.nl
Tue Mar 1 08:00:22 EST 2011
Op 01-03-11 09:17, Shane Hathaway schreef:
> On 02/28/2011 07:37 PM, Shane Hathaway wrote:
>> On 02/28/2011 08:19 AM, Maurits van Rees wrote:
>>> I wonder if there is some code that mistakenly throws away the wrong
>>> blob; it should throw away the oldest one I'd think, and not the one
>>> that it just loaded.
>>>
>>> The workaround is probably just to not set the blob-cache-size this low.
>>> But I tried this low setting to work around a different problem, which
>>> I will report in a different post.
>>
>> This reveals how naive the blob cache management is in both RelStorage
>> and ZEO. It is smart enough to use the atime of files (thus you should
>> not disable atime on a filesystem that hosts a blob cache), but the
>> cache management does not guarantee downloaded files are kept long
>> enough to actually read them.
>
> Oops, I take it back after reviewing the blob code tonight. ZODB 3.9
> and above is not naive about this issue. While ZODB 3.8 allows blob
> files to disappear at the wrong times, ZODB 3.9 has internal retry
> mechanisms that ensure blob files will be opened even when the blob
> cache size is too small.
>
> RelStorage can not fix this issue. If you want stable blob support, as
> Hanno said, you need ZODB 3.9 or above.
Not an option for the short term, as we are still on Plone 3, but good
to know, thanks.
--
Maurits van Rees
Web App Programmer at Zest Software: http://zestsoftware.nl
Personal website: http://maurits.vanrees.org/
More information about the ZODB-Dev
mailing list