On Tuesday 26 of October 2010, Graham Dumpleton wrote:
> On Tuesday, October 26, 2010, matkor <[email protected]> wrote:
> > I would like to delegate some actions  (like storing data, sending e-
> > mails etc ) after moment when my wsgi app have returned content via
> > wsgi interface.
> > How can this be implemented ?
> > Using mod_python I could have used IIRC cleanup handler which was
> > called after returning content to web browser.
> 
> For a start read:
> http://code.google.com/p/modwsgi/wiki/RegisteringCleanupCode
> (...)
> > I was thinking about adding another thread, but I have problem in
> > stability during restarts ('daemon' mode)
> 
> What problem?

apache pid process SEGFAULTed on exit.
But now with terminating and joining thread in atexit.register(cleanup) 
problem seems to be gone.

Is it intentional that printing in atexit.registered functions does not end up 
in error logs like other prints (at least during imports) ?

I see raised exceptions properly though ...

Big thanks for great help, regards,

-- 
Mateusz Korniak

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" 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/modwsgi?hl=en.

Reply via email to