[mod_python] Change site's structure to use mod_wsgi and outer product

Graham Dumpleton graham.dumpleton at gmail.com
Mon Apr 27 03:15:45 EDT 2009


2009/4/27 durumdara <durumdara at gmail.com>:
> Hi!
>
> I formerly wrote a mail to Graham and I said about a problem that I got in
> mod_py with reloading (the reloading is clear my variables in
> un-understandable way).
>
> To test another systems I want to try to change mod_py in my little site to
> django or pylons. Other virtual sites are remaining.
>
> But: many users warn me to python threading problems (for ex: Django and the
> main DB), and suggest me the mod_wsgi to avoid these problems.

It isn't mod_wsgi that is the solution, but certain modes of using it.
Anyway, Django 1.0.2 should be thread safe, but refer to page on
Django wiki about this linked from mod_wsgi wiki page on using Django
for latest information.

The real problem with Django is not its thread safety, but whether
people using Django understand threading enough to make their own code
thread safe.

> But yesterday I read this:
>
> 2009.04.25. 20:54 keltezéssel, Dave Britton írta:
>>
>> You can run mod_python and mod_wsgi on the same server, but in that
>> case certain features of mod_wsgi don't work as mod_python takes
>> control of initialising Python.
>>
>
> I wanna ask, that if this conflict with mod_wsgi/mod_py exists, how to I
> substitute my little site? The server serves 4 mod_py sites, and 4 php
> sites.
> I don't want to cause problems for these important sites.
> If this conflict can disturb the mod_py, my only way to make this
> substitution the mod_rewrite, and making proxy and trusting to this site
> never overloading...
>
> Or you can see any solution to do the substition without any problems? To
> use both mod_py and mod_wsgi in one time?
> I not use publisher.

The conflicts with mod_python and mod_wsgi aren't likely to be things
that will bother you.

All it is really about is that certain mod_wsgi directives designed to
customise how the Python interpreter is initialised will not work as
mod_python has already initialised the interpreter. In some cases it
just means you have to use the mod_python directive for the same
thing. For others it just means the inability to use some esoteric
feature that 99% or more of people wouldn't use anyway.

Graham

> The system: WX/2k3, Py2.5, mod_py2.3, apache 2.x.
>
> Thanks for your help:
>    dd
>
>
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://mailman.modpython.org/mailman/listinfo/mod_python
>



More information about the Mod_python mailing list