On Sep 18, 2008, at 11:08 AM, Tres Seaver wrote:

> Hash: SHA1
> Jim Fulton wrote:
>> Log message for revision 91235:
>>  Removed the feature to try to save the index periodically because:
>>  1. The saving was performed in (tpc)_finish.  It is important that  
>> this
>>     method do as little as possible because it cannot fail!
>>  2. The algorithm for deciding how often to save was broken. For  
>> large
>>     databases, for which saving periodically is desireable, the  
>> period
>>     was set so high that the index was effectively never saved.
>>  It might be nice to save periodically, but doing so is tricky, since
>>  we really don't want to do it during commit.  Until we figure out  
>> how
>>  to do this right, it is better not to try.
>>  In the mean time, we save on close and on pack, which is proably  
>> often
>>  enough in most cases.
> Perhaps we could extend the "zeopack" RPC mechanism with a special  
> value
> for the pack interval:  if passed, the server would just do the index
> save, and skip the real packing.
> People could then tune the interval by scripting.

Yeah, something like that.  I'm inclined to think that there should be  
some additional "control channel" for doing things like this.  Even  
for pack, additional options are often wanted. For example, pack wants  
an option to control whether to do GC, or whether to keep the old  
file. Obviously, we can't jam all of this into a cache interval.  This  
is, to some extend what the extension methods mechanism was for.   
Maybe this should simply be an extension method. Or maybe there should  
be a control channel outside of the client protocol.


Jim Fulton
Zope Corporation

For more information about ZODB, see the ZODB Wiki:

ZODB-Dev mailing list  -  ZODB-Dev@zope.org

Reply via email to