portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Sean Taylor" <da...@bluesunrise.com>
Subject RE: cvs commit: jakarta-jetspeed/src/java/org/apache/jetspeed/services/rundata DefaultJetspeedRunData.java
Date Tue, 14 May 2002 06:02:37 GMT
Glenn,

Just wondering about the philosophy behind the StateManager service, and
that it doesn't use the servlet session.
To continue in the spirit of your commit here, are you saying that we
should be moving everything out of the servlet session and into the
StateManager service? We put a lot of state into the servlet session. Do
you recommending that we ditch the standard way of storing state, i.e.
the servlet session, and instead use the StateManager, which manages its
own state into a singleton non-sync'd hashmap? 

Just wondering if this is the best approach. Some cons:

- have to duplicate a service that already exists
- no standard life cycle events from servlet api
- can't take advantage of servlet session sharing from some server impls
- its not standard

I believe the pro is:

- the servlet specification doesn't support 2 browser sessions on the
same machine with cookies turned on

As an aside,
I'm finally sitting down to adding the page id to the PortletConfig, and
Im having trouble getting the page id passed to Portlet Config.
Would've been a lot easier if I could've pulled the Profile out of the
session.... :(

Finally (I am a bit bitchy (tired) tonight) -- what is this header thing
at the top and bottom of the files that you checked in?:

/***********************************************************************
***********
*
* $Header:
/home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/statema
nager/JetspeedStateManagerService.java,v 1.2 2002/05/03 17:40:44 ggolden
Exp $
*
************************************************************************
**********/

David

> -----Original Message-----
> From: ggolden@apache.org [mailto:ggolden@apache.org] 
> Sent: Monday, May 13, 2002 6:04 AM
> To: jakarta-jetspeed-cvs@apache.org
> Subject: cvs commit: 
> jakarta-jetspeed/src/java/org/apache/jetspeed/services/rundata
>  DefaultJetspeedRunData.java
> 
> 
> ggolden     02/05/13 06:03:57
> 
>   Modified:    src/java/org/apache/jetspeed/modules/actions
>                         JetspeedAccessController.java
>                src/java/org/apache/jetspeed/services/rundata
>                         DefaultJetspeedRunData.java
>   Log:
>   Removed storage of Profile from User getTemp, replaced in 
> the JetspeedRunData.
>   The Profile is computed for each request and stored in the run data.
>   Storing a profile in the getTemp (i.e. the HTTP session) 
> introduces a conflict
>   when more than one window is open in the session to more 
> than one portal page.
>   
>   Revision  Changes    Path
>   1.3       +2 -11     
> jakarta-jetspeed/src/java/org/apache/jetspeed/modules/actions/
> JetspeedAccessController.java
>   
>   Index: JetspeedAccessController.java
>   ===================================================================
>   RCS file: 
> /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/module
> s/actions/JetspeedAccessController.java,v
>   retrieving revision 1.2
>   retrieving revision 1.3
>   diff -u -r1.2 -r1.3
>   --- JetspeedAccessController.java	23 Feb 2002 02:05:05 
> -0000	1.2
>   +++ JetspeedAccessController.java	13 May 2002 13:03:56 
> -0000	1.3
>   @@ -72,7 +72,7 @@
>        in order to get the cached ACL list from logon
>      
>    @author <a href="mailto:taylor@apache.org">David Sean Taylor</a>
>   -@version $Id: JetspeedAccessController.java,v 1.2 
> 2002/02/23 02:05:05 taylor Exp $
>   +@version $Id: JetspeedAccessController.java,v 1.3 
> 2002/05/13 13:03:56 ggolden Exp $
>    */
>    
>    public class JetspeedAccessController extends AccessController
>   @@ -95,15 +95,6 @@
>    
>           // get the profile and store it in the RunData
>            Profile newProfile = Profiler.getProfile(jdata);
>   -        Profile currentProfile = jdata.getProfile();
>   -        
>   -        if ((currentProfile == null)
>   -         || (!currentProfile.equals(newProfile)))
>   -        {
>   -            // the profile changed due to the request parameters,
>   -            // change it in the RunData
>   -            jdata.setProfile(newProfile);
>   -        }
>   - 
>   +        jdata.setProfile(newProfile);
>        }
>    }
>   
>   
>   
>   1.10      +3 -11     
> jakarta-jetspeed/src/java/org/apache/jetspeed/services/rundata
> /DefaultJetspeedRunData.java
>   
>   Index: DefaultJetspeedRunData.java
>   ===================================================================
>   RCS file: 
> /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/servic
> es/rundata/DefaultJetspeedRunData.java,v
>   retrieving revision 1.9
>   retrieving revision 1.10
>   diff -u -r1.9 -r1.10
>   --- DefaultJetspeedRunData.java	3 May 2002 15:05:56 
> -0000	1.9
>   +++ DefaultJetspeedRunData.java	13 May 2002 13:03:57 
> -0000	1.10
>   @@ -79,7 +79,7 @@
>     * @author <a href="mailto:raphael@apache.org">Raphaƫl Luta</a>
>     * @author <a href="mailto:sgala@apache.org">Santiago Gala</a>
>     * @author <a href="mailto:paulsp@apache.org">Paul Spencer</a>
>   - * @version $Id: DefaultJetspeedRunData.java,v 1.9 
> 2002/05/03 15:05:56 ggolden Exp $
>   + * @version $Id: DefaultJetspeedRunData.java,v 1.10 
> 2002/05/13 13:03:57 ggolden Exp $
>     */
>    public class DefaultJetspeedRunData extends DefaultTurbineRunData
>        implements JetspeedRunData
>   @@ -271,7 +271,7 @@
>         */
>        public void setProfile(Profile profile)
>        {
>   -        this.getUser().setTemp("profile",profile);
>   +        this.profile = profile;
>        }
>    
>        /**
>   @@ -281,15 +281,7 @@
>         */
>        public Profile getProfile()
>        {
>   -    try
>   -    {
>   -        return (Profile)this.getUser().getTemp("profile");
>   -    } catch (Throwable t)
>   -    {
>   -        Log.error( "Captured Exception: " );
>   -        Log.error( t );
>   -    }
>   -    return null;
>   +        return this.profile;
>        }
>    
>        /** Clears the state of this object for recycling... */
>   
>   
>   
> 
> --
> To unsubscribe, e-mail:   
> <mailto:jetspeed-dev-> unsubscribe@jakarta.apache.org>
> For 
> additional commands, 
> e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>
> 
> 



--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message