[ZODB-Dev] ZEO and replication of BTree based objects

Shane Hathaway shane at zope.com
Thu Jun 5 14:53:44 EDT 2003


Jeremy Hylton wrote:
> I think it would be great to have a prefetching mechanism in ZEO,
> probably coupled with a notification system to let the app know when an
> object is loaded.

It seems like prefetching is actually easy to do.  You just create a 
thread in the ZEO client that draws from some kind of OID queue, calling 
storage.load() for each OID.  Each successful load() adds to the local 
ZEO cache and possibly notifies the application.  This wouldn't require 
any changes to ZODB.

What isn't clear is how you fill the OID queue.  How can you know the 
OIDs of the objects that are important enough to prefetch?

Shane




More information about the ZODB-Dev mailing list