gatein SVN: r1953 - portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal.
by do-not-reply@jboss.org
Author: thomas.heute(a)jboss.com
Date: 2010-03-03 11:54:16 -0500 (Wed, 03 Mar 2010)
New Revision: 1953
Modified:
portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
Log:
Oups committed testing stuff (GTNPORTAL-770)
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml 2010-03-03 16:52:07 UTC (rev 1952)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml 2010-03-03 16:54:16 UTC (rev 1953)
@@ -205,47 +205,6 @@
</init-params>
</component>
- <component>
-<type>org.exoplatform.container.definition.PortalContainerConfig</type>
-<component-plugins>
- <component-plugin> <!-- The name of the plugin --> <name>Add PortalContainer Definitions</name> <!-- The name of the method to call on the PortalContainerConfig in order to register the PortalContainerDefinitions --> <set-method>registerPlugin</set-method> <!-- The full qualified name of the PortalContainerDefinitionPlugin -->
- <type>org.exoplatform.container.definition.PortalContainerDefinitionPlugin</type>
- <init-params>
- <object-param>
- <name>portal</name>
- <object type="org.exoplatform.container.definition.PortalContainerDefinition">
- <!-- The name of the portal container -->
- <field name="name"><string>portal</string></field>
- <!-- The name of the context name of the rest web application -->
- <field name="restContextName"><string>rest</string></field>
- <!-- The name of the realm -->
- <field name="realmName"><string>gatein-domain</string></field>
- <!-- All the dependencies of the portal container ordered by loading priority -->
- <field name="settings">
- <map type="java.util.HashMap">
- <entry>
- <key>
- <string>url</string>
- </key>
- <value>
- <string>value</string>
- </value>
- </entry>
- </map>
- </field>
- <field name="externalSettingsPath">
- <string>file://tmp/configuration.properties</string>
- </field>
-
-
- <field name="dependencies">
- <collection type="java.util.ArrayList">
- <value>
- <string>eXoResources</string>
-</value> <value> <string>portal</string> </value> <value> <string>dashboard</string> </value> <value> <string>exoadmin</string> </value> <value> <string>eXoGadgets</string> </value> <value> <string>eXoGadgetServer</string> </value> <value> <string>rest</string> </value> <value> <string>web</string> </value> </collection> </field> </object> </object-param> </init-params> </component-plugin>
-</component-plugins>
-</component>
-
<external-component-plugins>
<target-component>org.exoplatform.services.organization.OrganizationService</target-component>
<component-plugin>
14 years, 10 months
gatein SVN: r1952 - portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal.
by do-not-reply@jboss.org
Author: thomas.heute(a)jboss.com
Date: 2010-03-03 11:52:07 -0500 (Wed, 03 Mar 2010)
New Revision: 1952
Modified:
portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
Log:
GTNPORTAL-770: Enable JBoss Cache on the MOPSessionManager
Was defaulting to the default cache...
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml 2010-03-03 16:33:01 UTC (rev 1951)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/portal/portal-configuration.xml 2010-03-03 16:52:07 UTC (rev 1952)
@@ -205,6 +205,47 @@
</init-params>
</component>
+ <component>
+<type>org.exoplatform.container.definition.PortalContainerConfig</type>
+<component-plugins>
+ <component-plugin> <!-- The name of the plugin --> <name>Add PortalContainer Definitions</name> <!-- The name of the method to call on the PortalContainerConfig in order to register the PortalContainerDefinitions --> <set-method>registerPlugin</set-method> <!-- The full qualified name of the PortalContainerDefinitionPlugin -->
+ <type>org.exoplatform.container.definition.PortalContainerDefinitionPlugin</type>
+ <init-params>
+ <object-param>
+ <name>portal</name>
+ <object type="org.exoplatform.container.definition.PortalContainerDefinition">
+ <!-- The name of the portal container -->
+ <field name="name"><string>portal</string></field>
+ <!-- The name of the context name of the rest web application -->
+ <field name="restContextName"><string>rest</string></field>
+ <!-- The name of the realm -->
+ <field name="realmName"><string>gatein-domain</string></field>
+ <!-- All the dependencies of the portal container ordered by loading priority -->
+ <field name="settings">
+ <map type="java.util.HashMap">
+ <entry>
+ <key>
+ <string>url</string>
+ </key>
+ <value>
+ <string>value</string>
+ </value>
+ </entry>
+ </map>
+ </field>
+ <field name="externalSettingsPath">
+ <string>file://tmp/configuration.properties</string>
+ </field>
+
+
+ <field name="dependencies">
+ <collection type="java.util.ArrayList">
+ <value>
+ <string>eXoResources</string>
+</value> <value> <string>portal</string> </value> <value> <string>dashboard</string> </value> <value> <string>exoadmin</string> </value> <value> <string>eXoGadgets</string> </value> <value> <string>eXoGadgetServer</string> </value> <value> <string>rest</string> </value> <value> <string>web</string> </value> </collection> </field> </object> </object-param> </init-params> </component-plugin>
+</component-plugins>
+</component>
+
<external-component-plugins>
<target-component>org.exoplatform.services.organization.OrganizationService</target-component>
<component-plugin>
@@ -301,11 +342,11 @@
<description>add Exo Cache Config</description>
<init-params>
<object-param>
- <name>cache.config.PomSessionManager</name>
+ <name>cache.config.POMSessionManager</name>
<description>The JBoss Cache LRU configuration</description>
<object type="org.exoplatform.services.cache.impl.jboss.lru.LRUExoCacheConfig">
<field name="name">
- <string>PomSessionManager</string>
+ <string>POMSessionManager</string>
</field>
<field name="maxNodes">
<int>10000</int>
@@ -318,6 +359,7 @@
</init-params>
</component-plugin>
</external-component-plugins>
-
+
+
</configuration>
14 years, 10 months
gatein SVN: r1951 - in components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp: services and 1 other directory.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 11:33:01 -0500 (Wed, 03 Mar 2010)
New Revision: 1951
Modified:
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/handler/RequestHeaderClientHandler.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceWrapper.java
Log:
- GTNWSRP-6: Insert RequestHeaderClientHandler into the binding handler chain as this was previously not done.
This is done programmatically so that we can ensure that this handler will always be there and won't interfere
with potential customer customization.
- Moved customization of WS service object to ServiceWrapper as it's the whole point of wrapping the service. :)
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/handler/RequestHeaderClientHandler.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/handler/RequestHeaderClientHandler.java 2010-03-03 16:27:38 UTC (rev 1950)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/handler/RequestHeaderClientHandler.java 2010-03-03 16:33:01 UTC (rev 1951)
@@ -1,6 +1,6 @@
/*
* JBoss, a division of Red Hat
- * Copyright 2009, Red Hat Middleware, LLC, and individual
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
* contributors as indicated by the @authors tag. See the
* copyright.txt in the distribution for a full listing of
* individual contributors.
@@ -50,9 +50,11 @@
*/
public class RequestHeaderClientHandler implements SOAPHandler<SOAPMessageContext>
{
- private static final ThreadLocal local = new ThreadLocal();
+ private static final ThreadLocal<CurrentInfo> local = new ThreadLocal<CurrentInfo>();
private static final RFC2109Spec cookieParser = new RFC2109Spec();
private static final Logger log = LoggerFactory.getLogger(RequestHeaderClientHandler.class);
+ private static final String SET_COOKIE = "Set-Cookie";
+ private static final String COOKIE = "Cookie";
public Set<QName> getHeaders()
{
@@ -125,7 +127,7 @@
if (cookie.length() != 0)
{
- mimeHeaders.setHeader("Cookie", cookie.toString());
+ mimeHeaders.setHeader(COOKIE, cookie.toString());
}
return true;
@@ -136,7 +138,7 @@
SOAPMessageContext smc = (SOAPMessageContext)msgContext;
SOAPMessage message = smc.getMessage();
MimeHeaders mimeHeaders = message.getMimeHeaders();
- String[] cookieValues = mimeHeaders.getHeader("Set-Cookie");
+ String[] cookieValues = mimeHeaders.getHeader(SET_COOKIE);
if (cookieValues != null)
{
@@ -288,7 +290,7 @@
public static void setCurrentGroupId(String groupId)
{
- CurrentInfo currentInfo = (CurrentInfo)local.get();
+ CurrentInfo currentInfo = local.get();
if (currentInfo == null)
{
throw new IllegalStateException("Cannot set current group id when the current info hasn't been initialized.");
@@ -298,7 +300,7 @@
private static CurrentInfo getCurrentInfo(boolean createIfNeeded)
{
- CurrentInfo info = (CurrentInfo)local.get();
+ CurrentInfo info = local.get();
if (info == null && createIfNeeded)
{
info = new CurrentInfo(null, new ProducerSessionInformation());
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java 2010-03-03 16:27:38 UTC (rev 1950)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java 2010-03-03 16:33:01 UTC (rev 1951)
@@ -59,7 +59,6 @@
private boolean failed;
private boolean available;
private int msBeforeTimeOut = DEFAULT_TIMEOUT_MS;
- private static final String JBOSS_WS_STUBEXT_PROPERTY_CHUNKED_ENCODING_SIZE = "http://org.jboss.ws/http#chunksize";
public <T> T getService(Class<T> clazz) throws Exception
{
@@ -108,17 +107,9 @@
{
log.debug("Setting the end point to: " + portAddress);
}
- Map<String, Object> requestContext = ((BindingProvider)service).getRequestContext();
- requestContext.put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, portAddress);
- // Set org.jboss.ws.core.StubExt.PROPERTY_CHUNKED_ENCODING_SIZE to 0 to deactive chunked encoding for
- // better interoperability as Oracle's producer doesn't support it, for example.
- // See https://jira.jboss.org/jira/browse/JBWS-2884 and
- // http://community.jboss.org/wiki/JBossWS-NativeUserGuide#Chunked_encoding_...
- requestContext.put(JBOSS_WS_STUBEXT_PROPERTY_CHUNKED_ENCODING_SIZE, 0);
+ T result = ServiceWrapper.getServiceWrapper(clazz, service, portAddress, this);
- T result = ServiceWrapper.getServiceWrapper(clazz, service, this);
-
// if we managed to retrieve a service, we're probably available
setFailed(false);
setAvailable(true);
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceWrapper.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceWrapper.java 2010-03-03 16:27:38 UTC (rev 1950)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceWrapper.java 2010-03-03 16:33:01 UTC (rev 1951)
@@ -1,6 +1,6 @@
/*
* JBoss, a division of Red Hat
- * Copyright 2009, Red Hat Middleware, LLC, and individual
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
* contributors as indicated by the @authors tag. See the
* copyright.txt in the distribution for a full listing of
* individual contributors.
@@ -23,10 +23,16 @@
package org.gatein.wsrp.services;
+import org.gatein.wsrp.handler.RequestHeaderClientHandler;
+
+import javax.xml.ws.Binding;
import javax.xml.ws.BindingProvider;
+import javax.xml.ws.handler.Handler;
import javax.xml.ws.soap.SOAPFaultException;
import java.lang.reflect.ParameterizedType;
import java.rmi.RemoteException;
+import java.util.ArrayList;
+import java.util.List;
import java.util.Map;
/**
@@ -49,6 +55,9 @@
private static final String SUN_WS_TIMEOUT = "com.sun.xml.ws.request.timeout";
private static final String IBM_WS_TIMEOUT = "com.ibm.SOAP.requestTimeout";
+ private static final RequestHeaderClientHandler REQUEST_HEADER_CLIENT_HANDLER = new RequestHeaderClientHandler();
+ private static final String JBOSS_WS_STUBEXT_PROPERTY_CHUNKED_ENCODING_SIZE = "http://org.jboss.ws/http#chunksize";
+
protected ServiceWrapper(Object service, ManageableServiceFactory parentFactory)
{
if (service == null)
@@ -60,7 +69,7 @@
// set timeout properties for different WS stacks
BindingProvider bindingProvider = (BindingProvider)service;
- setTimeout(bindingProvider, parentFactory);
+ setTimeout(bindingProvider.getRequestContext(), parentFactory);
Class tClass = (Class)((ParameterizedType)getClass().getGenericSuperclass()).getActualTypeArguments()[0];
@@ -75,18 +84,50 @@
this.parentFactory = parentFactory;
}
- private static void setTimeout(BindingProvider bindingProvider, ManageableServiceFactory parentFactory)
+ private static void setTimeout(Map<String, Object> requestContext, ManageableServiceFactory parentFactory)
{
- Map<String, Object> requestContext = bindingProvider.getRequestContext();
- requestContext.put(JBOSS_WS_TIMEOUT, parentFactory.getWSOperationTimeOut());
- requestContext.put(SUN_WS_TIMEOUT, parentFactory.getWSOperationTimeOut());
- requestContext.put(IBM_WS_TIMEOUT, parentFactory.getWSOperationTimeOut());
+ int timeout = parentFactory.getWSOperationTimeOut();
+ requestContext.put(JBOSS_WS_TIMEOUT, timeout);
+ requestContext.put(SUN_WS_TIMEOUT, timeout);
+ requestContext.put(IBM_WS_TIMEOUT, timeout);
}
- public static <T> T getServiceWrapper(Class<T> expectedServiceInterface, Object service, ManageableServiceFactory parentFactory)
+ public static <T> T getServiceWrapper(Class<T> expectedServiceInterface, Object service, String portAddress, ManageableServiceFactory parentFactory)
{
- // for now, only set timeouts
- setTimeout((BindingProvider)service, parentFactory);
+ BindingProvider bindingProvider = (BindingProvider)service;
+ Map<String, Object> requestContext = bindingProvider.getRequestContext();
+
+ // set timeout
+ setTimeout(requestContext, parentFactory);
+
+ // set port address
+ requestContext.put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, portAddress);
+
+ // Set org.jboss.ws.core.StubExt.PROPERTY_CHUNKED_ENCODING_SIZE to 0 to deactive chunked encoding for
+ // better interoperability as Oracle's producer doesn't support it, for example.
+ // See https://jira.jboss.org/jira/browse/JBWS-2884 and
+ // http://community.jboss.org/wiki/JBossWS-NativeUserGuide#Chunked_encoding_...
+ requestContext.put(JBOSS_WS_STUBEXT_PROPERTY_CHUNKED_ENCODING_SIZE, 0);
+
+ // Add client side handler via JAX-WS API
+ Binding binding = bindingProvider.getBinding();
+ List<Handler> handlerChain = binding.getHandlerChain();
+ if (handlerChain != null)
+ {
+ // if we already have a handler chain, just add the request hearder handler if it's not already in there
+ if (!handlerChain.contains(REQUEST_HEADER_CLIENT_HANDLER))
+ {
+ handlerChain.add(REQUEST_HEADER_CLIENT_HANDLER);
+ }
+ }
+ else
+ {
+ // otherwise, create a handler chain and add our handler to it
+ handlerChain = new ArrayList<Handler>(1);
+ handlerChain.add(REQUEST_HEADER_CLIENT_HANDLER);
+ }
+ binding.setHandlerChain(handlerChain);
+
return expectedServiceInterface.cast(service);
}
14 years, 10 months
gatein SVN: r1950 - components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 11:27:38 -0500 (Wed, 03 Mar 2010)
New Revision: 1950
Modified:
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/SessionHandler.java
Log:
- Minor optimization.
- Changed SESSION_ID_PREFIX value to org.gatein.wsrp.session. to be more consistent.
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/SessionHandler.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/SessionHandler.java 2010-03-03 16:01:31 UTC (rev 1949)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/SessionHandler.java 2010-03-03 16:27:38 UTC (rev 1950)
@@ -1,6 +1,6 @@
/*
* JBoss, a division of Red Hat
- * Copyright 2009, Red Hat Middleware, LLC, and individual
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
* contributors as indicated by the @authors tag. See the
* copyright.txt in the distribution for a full listing of
* individual contributors.
@@ -41,11 +41,11 @@
import javax.servlet.http.HttpSession;
import java.util.ArrayList;
-import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
/**
* Manages session informations on behalf of a consumer.
@@ -63,10 +63,10 @@
private CookieProtocol requiresInitCookie;
/** The prefix used to isolate WSRP-related session information in the actual session object. */
- private static final String SESSION_ID_PREFIX = "org.jboss.portal.wsrp.session.";
+ private static final String SESSION_ID_PREFIX = "org.gatein.wsrp.session.";
/** session id -> ProducerSessionInformation */
- private Map<String, ProducerSessionInformation> sessionInfos = new HashMap<String, ProducerSessionInformation>(); // todo: thread-safe?
+ private Map<String, ProducerSessionInformation> sessionInfos = new ConcurrentHashMap<String, ProducerSessionInformation>(); // todo: thread-safe?
/**
* Constructs a new SessionHandler.
@@ -216,7 +216,10 @@
{
ProducerSessionInformation sessionInfo = getProducerSessionInformation(invocation, true);
ProducerSessionInformation currentSessionInfo = RequestHeaderClientHandler.getCurrentProducerSessionInformation();
- sessionInfo.replaceUserCookiesWith(currentSessionInfo);
+ if (sessionInfo != currentSessionInfo)
+ {
+ sessionInfo.replaceUserCookiesWith(currentSessionInfo);
+ }
}
ProducerSessionInformation getProducerSessionInformation(PortletInvocation invocation)
14 years, 10 months
gatein SVN: r1949 - components/wsrp/trunk/common/src/main/java/org/gatein/wsrp.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 11:01:31 -0500 (Wed, 03 Mar 2010)
New Revision: 1949
Modified:
components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPRenderURL.java
Log:
- Return null instead of throwing an exception in getPublicNavigationalStateChanges.
Modified: components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPRenderURL.java
===================================================================
--- components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPRenderURL.java 2010-03-03 15:40:30 UTC (rev 1948)
+++ components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPRenderURL.java 2010-03-03 16:01:31 UTC (rev 1949)
@@ -1,6 +1,6 @@
/*
* JBoss, a division of Red Hat
- * Copyright 2009, Red Hat Middleware, LLC, and individual
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
* contributors as indicated by the @authors tag. See the
* copyright.txt in the distribution for a full listing of
* individual contributors.
@@ -24,10 +24,10 @@
package org.gatein.wsrp;
import org.gatein.pc.api.Mode;
-import org.gatein.pc.api.WindowState;
import org.gatein.pc.api.OpaqueStateString;
import org.gatein.pc.api.RenderURL;
import org.gatein.pc.api.StateString;
+import org.gatein.pc.api.WindowState;
import java.util.Map;
@@ -74,7 +74,7 @@
public Map<String, String[]> getPublicNavigationalStateChanges()
{
- throw new UnsupportedOperationException("getPublicNavigationalStateChanges is not currently supported!"); // todo: fix me
+ return null; // todo: fix me
}
protected void appendEnd(StringBuffer sb)
14 years, 10 months
gatein SVN: r1948 - portal/trunk/component/web/src/main/java/org/exoplatform/web/login.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-03-03 10:40:30 -0500 (Wed, 03 Mar 2010)
New Revision: 1948
Modified:
portal/trunk/component/web/src/main/java/org/exoplatform/web/login/InitiateLoginServlet.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/login/PortalLoginController.java
Log:
- actually now makes initialURI more useable than what it used to be
- minor improvement
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/login/InitiateLoginServlet.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/login/InitiateLoginServlet.java 2010-03-03 15:21:59 UTC (rev 1947)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/login/InitiateLoginServlet.java 2010-03-03 15:40:30 UTC (rev 1948)
@@ -48,8 +48,10 @@
*/
private static final long serialVersionUID = -2553824531076121642L;
+ /** . */
public static final String COOKIE_NAME = "rememberme";
+ /** . */
public static final String CREDENTIALS = "credentials";
@Override
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/login/PortalLoginController.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/login/PortalLoginController.java 2010-03-03 15:21:59 UTC (rev 1947)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/login/PortalLoginController.java 2010-03-03 15:40:30 UTC (rev 1948)
@@ -48,21 +48,31 @@
//
String username = req.getParameter("username");
String password = req.getParameter("password");
+
+ //
+ if (username == null)
+ {
+ resp.sendError(HttpServletResponse.SC_BAD_REQUEST, "No username provided");
+ }
+ if (password == null)
+ {
+ resp.sendError(HttpServletResponse.SC_BAD_REQUEST, "No password provided");
+ }
+
+ //
Credentials credentials = new Credentials(username, password);
req.getSession().setAttribute(InitiateLoginServlet.CREDENTIALS, credentials);
- String uri = (String)req.getSession().getAttribute("initialURI");
+ // Obtain initial URI
+ String uri = req.getParameter("initialURI");
+
+ // otherwise compute one
if (uri == null || uri.length() == 0)
{
- String pathInfo = req.getPathInfo();
- if (pathInfo == null)
- {
- pathInfo = "/";
- }
- uri = req.getContextPath() + "/private" + pathInfo;
+ uri = req.getContextPath() + "/private/classic";
}
- //
+ // if we do have a remember me
String rememberme = req.getParameter("rememberme");
if ("true".equals(rememberme))
{
@@ -78,6 +88,8 @@
resp.addCookie(cookie);
}
}
+
+ //
resp.sendRedirect(uri);
}
14 years, 10 months
gatein SVN: r1947 - portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 10:21:59 -0500 (Wed, 03 Mar 2010)
New Revision: 1947
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java
Log:
- Reformat.
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java 2010-03-03 15:20:52 UTC (rev 1946)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java 2010-03-03 15:21:59 UTC (rev 1947)
@@ -116,14 +116,14 @@
if (!type.equals(Constants.PORTAL_RENDER))
{
- appendParameter(baseURL, Constants.TYPE_PARAMETER, type);
+ appendParameter(baseURL, Constants.TYPE_PARAMETER, type);
}
-
+
if (format != null && format.getWantSecure() != null)
{
- appendParameter(baseURL, Constants.SECURE_PARAMETER, format.getWantSecure().toString());
+ appendParameter(baseURL, Constants.SECURE_PARAMETER, format.getWantSecure().toString());
}
-
+
if (containerURL instanceof ActionURL)
{
ActionURL actionURL = (ActionURL)containerURL;
@@ -133,9 +133,9 @@
{
appendParameter(baseURL, INTERACTION_STATE_PARAM_NAME, state.getStringValue());
}
-
+
state = actionURL.getNavigationalState();
- if (state != null && !state.getStringValue().equals(StateString.JBPNS_PREFIX) )
+ if (state != null && !state.getStringValue().equals(StateString.JBPNS_PREFIX))
{
appendParameter(baseURL, NAVIGATIONAL_STATE_PARAM_NAME, state.getStringValue());
}
@@ -209,18 +209,18 @@
{
for (String key : publicNSChanges.keySet())
{
- String[] values = publicNSChanges.get(key);
- if (values != null && values.length > 0)
- {
- for (String value : values)
- {
- appendParameter(baseURL, key, value);
- }
- }
- else
- {
- appendParameter(baseURL, "removePP", key);
- }
+ String[] values = publicNSChanges.get(key);
+ if (values != null && values.length > 0)
+ {
+ for (String value : values)
+ {
+ appendParameter(baseURL, key, value);
+ }
+ }
+ else
+ {
+ appendParameter(baseURL, "removePP", key);
+ }
}
}
14 years, 10 months
gatein SVN: r1946 - in portal/trunk: component/test/organization/src/main/resources/conf and 1 other directories.
by do-not-reply@jboss.org
Author: thomas.heute(a)jboss.com
Date: 2010-03-03 10:20:52 -0500 (Wed, 03 Mar 2010)
New Revision: 1946
Modified:
portal/trunk/component/identity/src/test/java/conf/portal/idm-configuration.xml
portal/trunk/component/test/organization/src/main/resources/conf/exo.portal.component.test.organization-configuration.xml
portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml
Log:
GTNPORTAL-795: Remove usage of "hibernate.cglib.use_reflection_optimizer"
Modified: portal/trunk/component/identity/src/test/java/conf/portal/idm-configuration.xml
===================================================================
--- portal/trunk/component/identity/src/test/java/conf/portal/idm-configuration.xml 2010-03-03 15:20:11 UTC (rev 1945)
+++ portal/trunk/component/identity/src/test/java/conf/portal/idm-configuration.xml 2010-03-03 15:20:52 UTC (rev 1946)
@@ -104,7 +104,6 @@
<property name="hibernate.cache.use_query_cache" value="true"/>
<!--CHANGEME HashtableCacheProvider shold not be used in production env-->
<property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
- <property name="hibernate.cglib.use_reflection_optimizer" value="true"/>
<property name="hibernate.connection.url" value="jdbc:hsqldb:file:${basedir}/target/temp/data/exodb${container.name.suffix}"/>
<property name="hibernate.connection.driver_class" value="org.hsqldb.jdbcDriver"/>
<property name="hibernate.connection.autocommit" value="true"/>
Modified: portal/trunk/component/test/organization/src/main/resources/conf/exo.portal.component.test.organization-configuration.xml
===================================================================
--- portal/trunk/component/test/organization/src/main/resources/conf/exo.portal.component.test.organization-configuration.xml 2010-03-03 15:20:11 UTC (rev 1945)
+++ portal/trunk/component/test/organization/src/main/resources/conf/exo.portal.component.test.organization-configuration.xml 2010-03-03 15:20:52 UTC (rev 1946)
@@ -76,7 +76,6 @@
<property name="hibernate.cache.use_query_cache" value="true"/>
<!--CHANGEME HashtableCacheProvider shold not be used in production env-->
<property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
- <property name="hibernate.cglib.use_reflection_optimizer" value="true"/>
<property name="hibernate.connection.datasource" value="jdbcidm"/>
<property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
<property name="hibernate.c3p0.min_size" value="5"/>
@@ -142,4 +141,4 @@
</init-params>
</component-plugin>
</external-component-plugins>
-</configuration>
\ No newline at end of file
+</configuration>
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml 2010-03-03 15:20:11 UTC (rev 1945)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/conf/organization/idm-configuration.xml 2010-03-03 15:20:52 UTC (rev 1946)
@@ -39,7 +39,6 @@
<property name="hibernate.cache.use_query_cache" value="true"/>
<!--CHANGEME HashtableCacheProvider shold not be used in production env-->
<property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
- <property name="hibernate.cglib.use_reflection_optimizer" value="true"/>
<property name="hibernate.connection.datasource" value="${gatein.idm.datasource.name}${container.name.suffix}"/>
<property name="hibernate.connection.autocommit" value="true"/>
<!--
14 years, 10 months
gatein SVN: r1945 - portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 10:20:11 -0500 (Wed, 03 Mar 2010)
New Revision: 1945
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java
Log:
- Do not process public navigational state if there is none.
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java 2010-03-03 15:09:27 UTC (rev 1944)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/ExoPortletInvocationContext.java 2010-03-03 15:20:11 UTC (rev 1945)
@@ -23,6 +23,7 @@
import org.exoplatform.portal.application.PortalRequestContext;
import org.gatein.common.net.media.MediaType;
import org.gatein.common.util.MarkupInfo;
+import org.gatein.common.util.ParameterValidation;
import org.gatein.pc.api.ActionURL;
import org.gatein.pc.api.ContainerURL;
import org.gatein.pc.api.Mode;
@@ -204,7 +205,7 @@
}
Map<String, String[]> publicNSChanges = renderURL.getPublicNavigationalStateChanges();
- if (publicNSChanges != null)
+ if (ParameterValidation.existsAndIsNotEmpty(publicNSChanges))
{
for (String key : publicNSChanges.keySet())
{
14 years, 10 months
gatein SVN: r1944 - in components/pc/trunk/samples/src/main/artifacts: google-portlet-war/WEB-INF and 1 other directory.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-03-03 10:09:27 -0500 (Wed, 03 Mar 2010)
New Revision: 1944
Modified:
components/pc/trunk/samples/src/main/artifacts/basic-portlet-war/WEB-INF/portlet.xml
components/pc/trunk/samples/src/main/artifacts/google-portlet-war/WEB-INF/portlet.xml
Log:
- Added SessionPortlet and SessionCounterPortlet definitions and marked them as remotable.
- Marked Google portlets as remotable.
Modified: components/pc/trunk/samples/src/main/artifacts/basic-portlet-war/WEB-INF/portlet.xml
===================================================================
--- components/pc/trunk/samples/src/main/artifacts/basic-portlet-war/WEB-INF/portlet.xml 2010-03-03 15:07:51 UTC (rev 1943)
+++ components/pc/trunk/samples/src/main/artifacts/basic-portlet-war/WEB-INF/portlet.xml 2010-03-03 15:09:27 UTC (rev 1944)
@@ -1,26 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ This is free software; you can redistribute it and/or modify it
+ ~ under the terms of the GNU Lesser General Public License as
+ ~ published by the Free Software Foundation; either version 2.1 of
+ ~ the License, or (at your option) any later version.
+ ~
+ ~ This software is distributed in the hope that it will be useful,
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ ~ Lesser General Public License for more details.
+ ~
+ ~ You should have received a copy of the GNU Lesser General Public
+ ~ License along with this software; if not, write to the Free
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ -->
<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
@@ -33,7 +33,7 @@
<portlet-name>ExceptionPortlet</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.ExceptionPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<portlet-info>
<title>Exception portlet</title>
@@ -41,10 +41,44 @@
</portlet>
<portlet>
+ <portlet-name>SessionPortlet</portlet-name>
+ <display-name>Session Portlet</display-name>
+ <portlet-class>org.gatein.pc.samples.basic.SessionPortlet</portlet-class>
+ <supports>
+ <mime-type>text/html</mime-type>
+ </supports>
+ <portlet-info>
+ <title>Session portlet</title>
+ <keywords>sample,session</keywords>
+ </portlet-info>
+ <container-runtime-option>
+ <name>org.gatein.pc.remotable</name>
+ <value>true</value>
+ </container-runtime-option>
+ </portlet>
+
+ <portlet>
+ <portlet-name>SessionCounterPortlet</portlet-name>
+ <display-name>Session Counter Portlet</display-name>
+ <portlet-class>org.gatein.pc.samples.basic.SessionCounterPortlet</portlet-class>
+ <supports>
+ <mime-type>text/html</mime-type>
+ </supports>
+ <portlet-info>
+ <title>Session Counter portlet</title>
+ <keywords>sample,session</keywords>
+ </portlet-info>
+ <container-runtime-option>
+ <name>org.gatein.pc.remotable</name>
+ <value>true</value>
+ </container-runtime-option>
+ </portlet>
+
+ <portlet>
<portlet-name>AJAXResourcePortlet</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.AJAXResourcePortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<supports>
<mime-type>text/javascript</mime-type>
@@ -58,7 +92,7 @@
<portlet-name>HeaderInjectionPortlet</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.HeaderInjectionPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<supports>
<mime-type>text/javascript</mime-type>
@@ -72,7 +106,7 @@
<portlet-name>FailDuringInitPortlet</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.FailDuringInitPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<portlet-info>
<title>Fail during init portlet</title>
@@ -83,7 +117,7 @@
<portlet-name>RandomEventPortlet1</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.RandomEventPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<portlet-info>
<title>A portlet that generate events randomly</title>
@@ -111,7 +145,7 @@
<portlet-name>RandomEventPortlet2</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.RandomEventPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<portlet-info>
<title>A portlet that generate events randomly</title>
@@ -140,7 +174,7 @@
<portlet-name>RandomEventPortlet3</portlet-name>
<portlet-class>org.gatein.pc.samples.basic.RandomEventPortlet</portlet-class>
<supports>
- <mime-type>text/html</mime-type>
+ <mime-type>text/html</mime-type>
</supports>
<portlet-info>
<title>A portlet that generate events randomly</title>
Modified: components/pc/trunk/samples/src/main/artifacts/google-portlet-war/WEB-INF/portlet.xml
===================================================================
--- components/pc/trunk/samples/src/main/artifacts/google-portlet-war/WEB-INF/portlet.xml 2010-03-03 15:07:51 UTC (rev 1943)
+++ components/pc/trunk/samples/src/main/artifacts/google-portlet-war/WEB-INF/portlet.xml 2010-03-03 15:09:27 UTC (rev 1944)
@@ -1,26 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2008, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ This is free software; you can redistribute it and/or modify it
+ ~ under the terms of the GNU Lesser General Public License as
+ ~ published by the Free Software Foundation; either version 2.1 of
+ ~ the License, or (at your option) any later version.
+ ~
+ ~ This software is distributed in the hope that it will be useful,
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ ~ Lesser General Public License for more details.
+ ~
+ ~ You should have received a copy of the GNU Lesser General Public
+ ~ License along with this software; if not, write to the Free
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ -->
<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd"
@@ -119,5 +119,10 @@
<identifier>zipcode</identifier>
<qname xmlns:g='urn:jboss:portal:simple:google'>g:zipcode</qname>
</public-render-parameter>
+
+ <container-runtime-option>
+ <name>org.gatein.pc.remotable</name>
+ <value>true</value>
+ </container-runtime-option>
</portlet-app>
14 years, 10 months