[Product-Developers] IObjectAddedEvent fires 5 times instead of 1 time

Mikko Ohtamaa mikko+plone at redinnovation.com
Thu Dec 22 17:47:39 UTC 2011


On Thu, Dec 22, 2011 at 7:03 PM, Maarten Nieber <maarten at usecm.com> wrote:
> Hi,
>
> I registered a handler for the IObjectAddedEvent, but it gets fired 5 times
> instead of one (I have a set_trace in the event handler), one time when before
> the add page for the new IHomePage instance is shown, and various times after
> clicking Save.

http://collective-docs.readthedocs.org/en/latest/components/events.html#creation-events

> ps Also, at some point, this error shows up in the debugger console
>
> 2011-12-22 17:53:41 INFO ZPublisher.Conflict ConflictError at
> /em/portal_factory/HomePage/homepage.2011-12-22.5472924060/kssValidateField:
> database conflict error (oid 0x0161, class BTrees.IOBTree.IOBTree, serial this
> txn started with 0x039343b47fa46055 2011-12-22 16:52:29.916116, serial currently
> committed 0x039343b5ad5c9b11 2011-12-22 16:53:40.631658) (2 conflicts (0
> unresolved) since startup at Thu Dec 22 17:48:43 2011)

The transaction will rollback and Zope will retry HTTP request until
it completes without ConflictError or retry limit has been reached.

-- 
Mikko Ohtamaa
http://opensourcehacker.com
http://twitter.com/moo9000


More information about the Product-Developers mailing list