On Jun 28, 11:46 am, Ian Bicking <[EMAIL PROTECTED]> wrote:
>
> So as middleware I think it should be fine. If you want to catch a
> problem with the commit and handle it gracefully, I think you can just
> do your own commit in your code (and the middleware commit will just
> commit what little happens after that).
>
> And of course, what you put in as a transaction is up to you. You could
> put in some object which uses whatever flags you want to actually pass
> through a commit or else just ignore it.
usually, applications want a single big "transaction" for the whole
request. if an app wants something that will commit independently of
the "enclosing" transaction, that can be an option to the decorator:
@transactional(independent=True)
def do_something(self):
the term "independent" is made up and maybe not so clear...but again,
this is straight out of EJB. they let you annotate session beans in
an XML file using these terms: "required", "requiresNew", "Supports",
"Mandatory", "NotSupported", "Never". I think we should consider each
of these cases and determine if we think we need to support that case,
and if so how. (also does Zope express this many variants?)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"pylons-discuss" 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/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---