You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mod_python-dev@quetz.apache.org by "Graham Dumpleton (JIRA)" <ji...@apache.org> on 2005/07/23 13:45:45 UTC

[jira] Commented: (MODPYTHON-59) Add get_session() method to request object

    [ http://issues.apache.org/jira/browse/MODPYTHON-59?page=comments#action_12316577 ] 

Graham Dumpleton commented on MODPYTHON-59:
-------------------------------------------

I previously commented on this on the mailing list but can't find the
email to reference.

The issue I raised was along the line that in order for this scheme to
be able to work nicely in with other code which creates and manages
session object, there probably also needs to be a way to determine if
the session object has already been created and to explicitly set the
sesssion, thereby bypassing the get_session() method. Ie., I don't
necessarily believe it should just be a black box whose behaviour
can't be overridden.

At minimum, it still should be possible to access the session object as
req.session and set it by assigning to req.session. Working code set
for 3.2 still doesn't appear to allow this.

Wish I could find the email as I may have suggested better reasons
in it. :-(

> Add get_session() method to request object
> ------------------------------------------
>
>          Key: MODPYTHON-59
>          URL: http://issues.apache.org/jira/browse/MODPYTHON-59
>      Project: mod_python
>         Type: New Feature
>   Components: core
>     Versions: 3.2.0
>  Environment: All
>     Reporter: Jim Gallacher

>
> Users will get session instances by calling req.get_session(). If a session already exists it will be returned, otherwise a new session instance will be created. Session configuration will be handled using apache directives rather than within their code.
> Using this scheme means only one session instance will be created per request, which will eliminate the deadlock problems many people experience. Also, using this scheme makes it possible for sessions to be properly handled within psp pages and across req.internal_redirect() calls.
> Code will be commited to svn shortly.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Re: [jira] Commented: (MODPYTHON-59) Add get_session() method to request object

Posted by Jim Gallacher <jg...@sympatico.ca>.
Graham Dumpleton (JIRA) wrote:
>     [ http://issues.apache.org/jira/browse/MODPYTHON-59?page=comments#action_12316577 ] 
> 
> Graham Dumpleton commented on MODPYTHON-59:
> -------------------------------------------
> 
> I previously commented on this on the mailing list but can't find the
> email to reference.
> 
> The issue I raised was along the line that in order for this scheme to
> be able to work nicely in with other code which creates and manages
> session object, there probably also needs to be a way to determine if
> the session object has already been created and to explicitly set the
> sesssion, thereby bypassing the get_session() method. Ie., I don't
> necessarily believe it should just be a black box whose behaviour
> can't be overridden.
> 
> At minimum, it still should be possible to access the session object as
> req.session and set it by assigning to req.session. Working code set
> for 3.2 still doesn't appear to allow this.
> 
> Wish I could find the email as I may have suggested better reasons
> in it. :-(

I hadn't forgotten - just hadn't got around to it. Spending some 
mod_python time tonight.

Regards,
Jim