Python web frameworks

BartlebyScrivener bscrivener42 at gmail.com
Tue Nov 20 21:37:03 EST 2007


On Nov 20, 3:39 pm, Graham Dumpleton <Graham.Dumple... at gmail.com>
wrote:

> This only holds if actually hosted on Apache. As Django these days
> supports WSGI interface there is nothing to stop it being run with
> other hosting solutions that support WSGI. So, you could host it under
> paster or CherryPy WSGI servers. You could even run it under CGI if
> you were really desperate using a CGI-WSGI adapter. So, it isn't
> strictly correct to say it is as a multiprocess framework specifically
> for mod_python, although the developers will admit in the first
> instance that they didn't design the internals with multithreading in
> mind. That said, there aren't believed to be any multithreading issues
> in Django itself at this time.
>
> People keep pushing this barrow about the GIL and multithreading being
> a huge problem, when in the context of Apache it is isn't, at least
> not to the degree people make out. The reason for this is that when
> using worker MPM it sill acts as a multi process web server even
> though each process is also multithreaded. Within those worker MPM
> child processes there is also a lot going on that doesn't involve
> Python code nor the GIL, for example initial request process and
> serving up of static files etc.
>
> Result is that the Python GIL is no impediment when using Apache on
> UNIX to making good use of multiple processors or cores, even when
> Apache worker MPM is used.
>

I understand about a fifth of this exchange but I'm glad it's here so
I can follow links and search on the terminology. I couldn't tell from
earlier posts if mod_python was good or bad.

The Django book says: "Apache with mod_python currently is the most
robust setup for using Django on a production server."

Is that true?  And if you start small with, say, an online arts
magazine for a metropolitan area, then can we easily scale if we
become popular?  I'm picking Django because it sounds like they did
just this with a newspaper site in Lawrence, Kansas.

We are thinking of starting with Webfaction and just seeing what
happens. All I know is that I like Python and Django and would rather
stick with open source.

Thanks for the info.

rd



More information about the Python-list mailing list