Well, this is definitely something we should document, but as a transaction manager, it has two choices, always create a transaction and commit it even when it's not needed, or only do it when needed. And the second should reduce DB overhead considerably, and for most serious webapps scaling the DB is where the first real trouble comes in. But perhaps zope.sqlalchemy ought to have an *option* to do the former rather than the latter.
But honestly creating your own extension that does that should not be hard either. Of course, there is a question worth asking about what the default TG2 behavior should be, but I'm somewhat predisposed to leaving it as is... --Mark Ramm On Wed, Mar 18, 2009 at 4:01 PM, Antoine Pitrou <[email protected]> wrote: > >> I had a similar problem recently and it was solved by updating >> zope.sqlalchemy from version 0.3 to 0.4. In the old version, bulk >> deletes did not mark the session as changed. >> > > Thanks, it solves the problem indeed. > > However, I wonder why zope.transaction relies on the *session* to be > mark as changed. I could perfectly have issued a non-ORM statement and > hoped for transaction.commit() to do what it claims to do, rather than > trying to be smart. > > Is there any zope.transaction developer here to enlighten me? > > > > -- Mark Ramm-Christensen email: mark at compoundthinking dot com blog: www.compoundthinking.com/blog --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/turbogears?hl=en -~----------~----~----~----~------~----~------~--~---

