> I found these cool decorators that stop the execution of the decorated > function after some given amount of time: > > http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/307871 > http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/440569 > http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/483752 > > These are different implementation with their own issues some of them > look better suited for TG some of them less but is there a common TG > idiom that people use for timing out controller method calls? Say for > instance the db lookup and processing takes too long I would like the > method to stop and the user should be notified along the lines of > "This takes unusually too long, try again later."
Seriously, no one does such a thing in TG? My main problem is that some of the recipes do the timing out of a function buy launching it in a separate thread but if there is have load on the application server too many threads might be launched. I'm also not sure if the other recipes are advisable in a TG environment. If anyone had constructive ideas I would be really grateful. Cheers, Daniel --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

