Re: patch that makes saveChanges optional on session destruction in zope
John Lenton <[email protected]> Mon, 21 Jun 2004 17:41:07 -0300
| Newsgroups | gmane.comp.python.modeling |
|---|---|
| Message-ID | <[email protected]> |
Sender: John Lenton <[email protected]> On Sun, Jun 20, 2004 at 05:38:29PM +0200, Sebastien Bigaret wrote: > > John Lenton <[email protected]> wrote: > > This patch adds a boolean property to the ZEditingContextSessioning > > zope product that controls whether saveChanges is called upon session > > destruction. Defaults to true (i.e., do saveChanges). > > > > It's a very simple patch, but it does what we needed (building a web > > application that needs to ensure atomicity of a complex object that is > > created in multiple stages). > > Thanks for the patch, it will be integrated into the next release. > Before releasing we'll need to update the documentation at > ZECSessioning/README and MDL/doc/UserGuide/FrameworkTypicalUsage.tex. > Email me privately if by any chance you think you could find some time > for this this week. hmm... now I'm not so certain the patch actually did what we wanted. In fact, reading the code, I see that saveChanges is called when bind_saveChanges_to_zope_transactions is true, and _finish is called on the ECProxy. AFAICT, saveChanges is *not* called on session destruction unless that property is set, and then it is called at every request end, right? Pass me the paper bag :( -- John Lenton ([email protected]) -- Random fortune: Government [is] an illusion the governed should not encourage. -- John Updike, "Couples" ------------------------------------------------------- This SF.Net email sponsored by Black Hat Briefings & Training. Attend Black Hat Briefings & Training, Las Vegas July 24-29 - digital self defense, top technical experts, no vendor pitches, unmatched networking opportunities. Visit www.blackhat.com