quetz-mod_python-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sterling Hughes <sterl...@bumblebury.com>
Subject Re: Talking About PSP: Interface
Date Thu, 10 Apr 2003 20:11:57 GMT
On Thu, 2003-04-10 at 16:17, Gregory (Grisha) Trubetskoy wrote:
> My battery is a little too low right now to go through this - but in
> general (and this may be a point of contention I understand)...
> 
> Many of these objects and functionalities do exist in mod_python, some
> could exist (but nobody wrote them yet, e.g. session), so it's important
> to keep it consistent across everything.
> 

Yep, I saw.  I think session by the way is absolutely crucial to PSP, so
I'll definitely look at writing it.

> Here is potential point of disagreement - mod_python is Apache-specific
> (that's why its name begins with "mod_", and the project is called
> Apache/Python integration). This means that the structure is heavily
> influenced and inspired by httpd. This is quite different from vast
> majority of other projects out there that strive to be platform
> independent.
> 
> IMHO apache is the best web server out there and will remain this way, and
> so to be as tightly linked to it as possible is a major advantage over all
> other server-independent solutions becuase they loose out on flexibility,
> scaleabilty and performance in order to sustain the level of abstraction.
> 

That's certainly *not* my intention.  Let me be clear: This is designed
for Apache.  While the lexer will be made available for general
adoption, I'm focusing on apache, because, well, I don't work with any
other webserver (unless I'm serving images).  

> So, for example, this is why mod_python does not have a "response" object,
> even though in Zope/Java/PHP/ASP/etc world there is a response object.
> This is because the mod_python request object didn't come about as a
> result of concious design of a web platform, but rather it's a direct
> mapping to Apache's request_rec C structure, same is for server
> (server_rec) or connection (conn_rec).
> 

Right.  And I think that's how it should be.  Mod_python is really quite
amazing to me, I didn't "get it," until you talked about how integration
could be done by adding a mod_python handler.  PSP however is concerned
more with the webpage portion of things, while mod_python (apache) is
concerned more with being a good server.  That's why I think the two
make a good pair.

> PSP can go two ways -
> 
> 1. Siding on the cross-platform side, abstracting mod_python objects with
> its own object structure.
> 
> 2. Reducing the abstraction level to niminum or none and just passing
> mod_python's objects directly to users.
> 
> My preference is with (2), and this, again, stems from my philosphy that
> mod_python is only as portable as Apache (and apache is pretty portable).
> 

You have no argument there.  My point in abstracting to response,
request, etc.  is not to abstract it away from apache (maybe that would
be useful, but I don't care about it. :)  Rather, I want to provide a
very simple API on top of the Apache stuff.  Maybe my design isn't that
simple, but that's what its there for.

Also note, that I wish for these abstractions to in no way conflict with
the core apache stuff.  That in my mind that *must* be available in
PSP.  I just wan't a very neat, relatively clean set of wrappers, which
make the functionality more comfortable/accessible.

> That is I made a concious decision not to get distracted by there ever
> being a Microsoft IIS version of mod_python (and if I ever were to make
> one, I'd charge at least $795 per copy) :-)

Ugh.  That's a good decision, you don't know pain until you've used
ISAPI.

-Sterling

-- 
Good judgement comes from experience, and experience comes from 
bad judgement. 
    - Fred Brooks


Mime
View raw message