You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by at...@apache.org on 2006/03/21 23:20:49 UTC

svn commit: r387646 - /portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java

Author: ate
Date: Tue Mar 21 14:20:45 2006
New Revision: 387646

URL: http://svn.apache.org/viewcvs?rev=387646&view=rev
Log:
http://issues.apache.org/jira/browse/JS2-174: Support Tomcat TCP Cluster
Session attributes needs to be Serializable.
In this case, the PortalReservedParameters.PREFERED_LANGUAGE_ATTRIBUTE (WeakHashMap) doesn't seem to be used anymore, so I simply removed it.

Modified:
    portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java

Modified: portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java?rev=387646&r1=387645&r2=387646&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java (original)
+++ portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/request/JetspeedRequestContext.java Tue Mar 21 14:20:45 2006
@@ -20,7 +20,6 @@
 import java.util.Iterator;
 import java.util.Locale;
 import java.util.Map;
-import java.util.WeakHashMap;
 
 import javax.security.auth.Subject;
 import javax.servlet.ServletConfig;
@@ -382,7 +381,9 @@
 
         if (preferedLocale == null || !locale.equals(preferedLocale))
         {
-            request.getSession().setAttribute(PortalReservedParameters.PREFERED_LANGUAGE_ATTRIBUTE, new WeakHashMap());
+            // PREFERED_LANGUAGE_ATTRIBUTE doesn't seem to be used anywhere anymore, and as a WeakHashMap isn't
+            // Serializable, "fixing" that problem (JS2-174) by simply not putting it in the session anymore
+            // request.getSession().setAttribute(PortalReservedParameters.PREFERED_LANGUAGE_ATTRIBUTE, new WeakHashMap());
             request.getSession().setAttribute(PortalReservedParameters.PREFERED_LOCALE_ATTRIBUTE, locale);
             request.setAttribute(PortalReservedParameters.PREFERED_LOCALE_ATTRIBUTE, locale);
         }



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org