[mod_python] Session data

Bo Lorentsen bl at netgroup.dk
Thu May 31 09:40:27 EST 2001


Chris Hagner wrote:

> In my experience, the quickest way to ensure that your web application
> scales poorly is to mis-use server-side user sessions (thereby agreeing with
> Grisha).  Now, that being said, not everyone needs this level of scalability
> AND user sessions are a standard part of almost every-single web application
> platform (ASP, Servlets/JSP, ColdFusion, etc.) commercially available.

This is the danger of the JavaServer/PHP approach, not been aware of this.

> BTW, I've found that most non-Apache-based web developers (of which I used
> to be one :-) are completely ignorant of the realities of running in a
> multi-process server.  They generally take for granted the user sessions
> built into whatever app server they're using and find it mentally
> challenging to truly believe they can live without such functionality.

Again, the tools they are using gives them this impression, or at least support
there view of the world. And then we have the same problem with ex. ASP as we
have with RAD tools --- the level of insight and experience.

> As for multiple-server user sessions, there are some solutions available in
> the non-Python space (most of the ones that I've seen use either a database
> (ugh :-) or a solution along the lines of Java's RMI to keep the session
> pool's in sync.  In either case, it is a non-trivial problem/solution and is
> best avoided (following the KISS principle).

Or even a CORBA version to keep the real-time aspect :-)

> You might want to check out WebWare (webware.sourceforge.net) as an expample
> web framework that has some session support.  I think they pickle objects to
> the file system.  There are some other python-based cgi frameworks that also
> support user sessions, but just be aware of how far such solutions will/will
> not take you.

I would be nervous about the performance and the real-time aspect by using the
file system approach, but thanks for the advise, I will look into it.

/BL




More information about the Mod_python mailing list