[mod_python] Faulty Impressions

Lee Brown administrator at leebrown.org
Sat Mar 4 16:59:18 EST 2006

I guess a good place to start is to note that mod python is not, in itself,
a web content framework nor a web application framework - it is an interface
between the Apache HTTP server and the Python programming language.  The
true beauty of mod python is, in my opinion, is that you can use it for,
well, any kind of HTTP-based service you need.  Anything written in Python,
or anything that will "speak nicely" to Python, can be implemented over HTTP
with mod python.
As an example, I use mod python for an extremely simple and straight-forward
content management system.  My content is XML data that is transformed via
XSLT into web pages.  When a request arrives at the server, a very simple
mod python handler maps the request URL to a pair of XML and HTML files. if
the file timestamp on the HTML file is newer than the XML file then the HTML
file is served as-is.  If the XML file is newer than the HTML file, an
external XSLT processor is called (LIBXSLT, in my case) to refresh the HTML
file and serve it.
I wrote this little content management system because I did not like any of
the "out-of-the box" CMS systems out there because they seemed much more
complicated than my needs.  But if you truly want a  full-bore content
management and delivery system, like CherryPy for example, you can do that,
So I guess one answer to your question is that mod python allows you to use
almost any means you can imagine (or at least write a program for) for doing
doing whatever it is you need your web application to do.

Best Regards,
Lee E. Brown
(administrator at leebrown.org)



From: mod_python-bounces at modpython.org
[mailto:mod_python-bounces at modpython.org] On Behalf Of Michael Guerrero
Sent: Saturday, March 04, 2006 7:47 AM
To: mod_python at modpython.org
Subject: [mod_python] Faulty Impressions


I'm new to mod_python and am planning a simple LAMPy application (brace
yourselves, newbness ensues).

Based on what I've found on the web (though certainly not an exhaustive
search), it appears mod_python is used for two kinds of web apps:

1. CGI -- making it much faster by embedding the interpreter.
2. PSP -- giving an easy, PHP-like use to Python for web development.

I haven't quite figured out how the different handlers fit into all this,
but am still perusing the documentation--having no knowledge of Apache or
how it works doesn't help ;^).

My question is, is there another means for creating dynamic web content
using mod_python (not talking about frameworks like Zope/Django).

Also, somewhat unrelated, how is the performance of using things like
pickled() objects and shelves versus relational databases when serving

If anyone has any good tutorials a link would be most appreciated.

- Mike Guerrero 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20060304/be892b5c/attachment.html

More information about the Mod_python mailing list