[Web-SIG] multi-threaded or multi-process wsgi apps
chris at simplistix.co.uk
Mon Nov 26 11:44:32 CET 2007
I hope I have the right list, if not please point me in the right
Likewise, if there are good docs that cover all of this, please send me
their way ;-)
Right, I'm curious as to how wsgi applications end up being
multi-threaded or multi-process and if they are, how they share
resources such as databases and configuration.
There's a couple of reasons I'm asking...
The first was something Chris McDonough said about one ofthe issues
they're having with the repoze project: when using something like
mod_wsgi, it's the first person to hit each thread that takes the hit of
loading the configuration and opening up the zodb. Opening the ZODB, in
particular, can take a lot of time. How should repoze be structured such
that all the threads load their config and open their databases when
apache is restarted rather than when each thread is first hit?
The second is a problem I see an app I'm working on heading towards. The
app has web-alterable configuration, so in a multi-threaded and
particular multi-process environment, I need some way to get the other
threads or processes to re-read their configuration when it has changed.
Hope you guys can help!
Simplistix - Content Management, Zope & Python Consulting
More information about the Web-SIG