[Zope-dev] [ZODB-Dev] Splitting a large ZODB file storage - any light-weight approach?
Hanno Schlichting
hanno at hannosch.eu
Wed Dec 30 09:02:51 EST 2009
On Wed, Dec 30, 2009 at 9:16 AM, Andreas Jung <lists at zopyx.com> wrote:
> Delete operations will trigger events modifying other global metadata
> related
> to the those objects. So this approach requires modification to the
> application in
> order to avoid such side effects.
But if you do it from a debug prompt, you can easily prevent those
events from being fired.
For a normal ObjectManager you do:
delattr(root, 'A') # this is what _delOb does
root._objects = tuple([i for i in root._objects if i['id'] != 'A'])
That's the actually important part of _delObject method, without
firing any events or calling any manage_ methods.
Hanno
More information about the Zope-Dev
mailing list