[ZODB-Dev] Analyzing the committed data during one transaction

Andreas Jung lists at zopyx.com
Mon Nov 17 08:21:39 EST 2008


On 15.11.2008 16:11 Uhr, Jim Fulton wrote:
>
> On Nov 15, 2008, at 10:03 AM, Andreas Jung wrote:
>
>> Hi there,
>>
>> is there a way to analyze the data committed during one transaction?
>> The current usecase is Plone. A simple change to a document causes a
>> large transaction (between 30k and 100k even for a one-char change). I
>> am interested to know how many of this data belongs to the
>> portal_catalog/index and how many are actually changes to the content
>> object itself (or subobjects).
>
>
> You can use a storage iterator to iterate over the data records in the
> transaction. You can analyse these records to see things like, their
> number, size and type.
>
> To look at a single transaction, pass the transaction id as the start
> transaction for the iterator. Then call next on the iterator to get an
> iterator for that transaction.
>

I am basically looking for "real-time monitoring" solution (hacked into 
the sources). Rephrasing my question in a different way: how can I get 
hold of the "parent" object based a persistent object with a _p_jar
connection? E.g. when the ZODB commits a subobject (e.g. a BTree or a 
bucket) of portal_catalog/Indexes/some_index then I would like to get 
hold of the the related parent "first-class" Zope 2 object (e.g. derived 
from SimpleItem/Item or something like that).

Andreas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lists.vcf
Type: text/x-vcard
Size: 316 bytes
Desc: not available
Url : http://mail.zope.org/pipermail/zodb-dev/attachments/20081117/961f8807/attachment.vcf 


More information about the ZODB-Dev mailing list