I have not a similar use case, but what i do with plone.app.async is a job launching another in a try catch and this job register the next execution which is "deferred". It register jobs with a begin_after attribute (see the plone.app.async defer branch & the zc.async documentation). Part of the implementation (the cron like system) is client code. I can give you nevertheless if interested, but i would have to remove bits :p.
As it is an infinite loop (register me again and again, time to time), it may be what you search in the idea to relaunch you jobs in error, say my transfer fail, i relaunch it in 1 minute. I had not success using the fallbacks as it would not let the job finnish with an OK status preventing me from relaunching the job as i lost the context & other stuff if i could remember well & your pdb confirms it, Please note that i don't remember if it is exactly why i choosed to handle errors my way (code is 6 monthes old and i had recent events that prevent my brain to work correctly :p )... Sorry. Also Yiorgis Gozadinos & folks have an new implementation enabling deferring for example but with a cleaner API that i am waiting for since a long time. Idea is that plone.app.async cannot add arguments without breaking API (misuse of *args, **kw), so for example in my branch i did add extra methods not to break existing stuff at the cost of an awful API. Maybe would it be good to commit this p.a.async2 somewhere as a preview ! [1] - http://svn.plone.org/svn/plone/plone.app.async/branches/defer/ -- Cordialement, KiOrKY GPG Key FingerPrint: 0x1A1194B7681112AF Pensez à l’environnement. N’imprimez ce courriel que si vous en avez vraiment besoin.
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Product-Developers mailing list [email protected] https://lists.plone.org/mailman/listinfo/plone-product-developers
