Hi, Actually I handle this use case using IObjectRemovedEvent subscribers. Can't see any other simple way... :-/
Best regards, Thierry 2016-04-21 9:36 GMT+02:00 Joe Steeve <[email protected]>: > How to maintain "referential integrity" in a ZODB. Simply put: When an > object-A is removed from a container, the references to object-A, in > other objects should go invalid. > > I tried holding a persistent.WeakRef whenever a reference was required. > However, the WeakRef seems to go invalid only after a GC on the db > (correct me if I am wrong). > > The other approach seems to be to use IObjectWillBeRemovedEvent at the > site of the referencing object, to act accordingly. > > How do other people deal with this? > > -- > Joe Steeve > HiPro IT Solutions Private Limited > http://hipro.co.in/ > > -- > You received this message because you are subscribed to the Google Groups > "pylons-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/pylons-discuss/1461224218.20052.19.camel%40hipro.co.in > . > For more options, visit https://groups.google.com/d/optout. > -- http://www.imagesdusport.com -- http://www.ztfy.org -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pylons-discuss/CAPX_VWD3hAh1Kx9PP9b6EoDo7p11JCxikn1YLJQgJ1xcUTdmXg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
