Author: chris.laprun(a)jboss.com
Date: 2011-08-25 08:22:29 -0400 (Thu, 25 Aug 2011)
New Revision: 7233
Added:
portal/trunk/wsrp-integration/extension-component/src/main/resources/conf/wsrp-consumers-config.xml
Modified:
portal/trunk/pom.xml
portal/trunk/wsrp-integration/extension-component/src/main/java/org/gatein/integration/wsrp/WSRPServiceIntegration.java
Log:
- GTNPORTAL-1938: updated to WSRP 2.1.0-Beta05, set the consumers configuration in a way
similar to what is done for the producer.
Modified: portal/trunk/pom.xml
===================================================================
--- portal/trunk/pom.xml 2011-08-25 11:13:07 UTC (rev 7232)
+++ portal/trunk/pom.xml 2011-08-25 12:22:29 UTC (rev 7233)
@@ -47,7 +47,7 @@
<org.gatein.wci.version>2.1.0-Beta06</org.gatein.wci.version>
<org.gatein.pc.version>2.3.0-Beta05</org.gatein.pc.version>
<org.picketlink.idm>1.3.0.Alpha03</org.picketlink.idm>
- <org.gatein.wsrp.version>2.1.0-Beta04</org.gatein.wsrp.version>
+ <org.gatein.wsrp.version>2.1.0-Beta05</org.gatein.wsrp.version>
<org.gatein.mop.version>1.1.0-Beta05</org.gatein.mop.version>
<org.gatein.mgmt.version>1.0.0-Beta02</org.gatein.mgmt.version>
<org.slf4j.version>1.5.8</org.slf4j.version>
Modified:
portal/trunk/wsrp-integration/extension-component/src/main/java/org/gatein/integration/wsrp/WSRPServiceIntegration.java
===================================================================
---
portal/trunk/wsrp-integration/extension-component/src/main/java/org/gatein/integration/wsrp/WSRPServiceIntegration.java 2011-08-25
11:13:07 UTC (rev 7232)
+++
portal/trunk/wsrp-integration/extension-component/src/main/java/org/gatein/integration/wsrp/WSRPServiceIntegration.java 2011-08-25
12:22:29 UTC (rev 7233)
@@ -89,11 +89,13 @@
private static final String PRODUCER_CONFIG_LOCATION =
"producerConfigLocation";
private static final String CONSUMERS_CONFIG_LOCATION =
"consumersConfigLocation";
- private final InputStream configurationIS;
+ private final InputStream producerConfigurationIS;
private final String producerConfigLocation;
private WSRPProducer producer;
- private ConsumerRegistry consumerRegistry;
+ private final InputStream consumersConfigurationIS;
+ private final String consumersConfigLocation;
+ private JCRConsumerRegistry consumerRegistry;
private ExoContainer container;
private final ExoKernelIntegration exoKernelIntegration;
private final boolean bypass;
@@ -107,7 +109,6 @@
// todo: we currently only allow the service to go through initialization if we are
running in the default portal
// as this service is not meant to work with extensions yet...
- String consumersConfigLocation;
if ("portal".equals(context.getName()))
{
if (params != null)
@@ -121,7 +122,8 @@
+ PRODUCER_CONFIG_LOCATION + "and " +
CONSUMERS_CONFIG_LOCATION);
}
- configurationIS = configurationManager.getInputStream(CLASSPATH +
producerConfigLocation);
+ producerConfigurationIS = configurationManager.getInputStream(CLASSPATH +
producerConfigLocation);
+ consumersConfigurationIS = configurationManager.getInputStream(CLASSPATH +
consumersConfigLocation);
container = context.getContainer();
@@ -136,7 +138,8 @@
producerConfigLocation = null;
consumersConfigLocation = null;
- configurationIS = null;
+ producerConfigurationIS = null;
+ consumersConfigurationIS = null;
exoKernelIntegration = null;
bypass = true;
}
@@ -176,7 +179,7 @@
persister.initializeBuilderFor(JCRProducerConfigurationService.mappingClasses);
producerConfigurationService = new JCRProducerConfigurationService(persister);
- producerConfigurationService.setDefaultConfigurationIS(configurationIS);
+ producerConfigurationService.setConfigurationIS(producerConfigurationIS);
producerConfigurationService.reloadConfiguration();
}
catch (Exception e)
@@ -304,6 +307,7 @@
consumerRegistry = new JCRConsumerRegistry(persister);
consumerRegistry.setFederatingPortletInvoker(federatingPortletInvoker);
consumerRegistry.setSessionEventBroadcaster(sessionEventBroadcaster);
+ consumerRegistry.setConfigurationIS(consumersConfigurationIS);
// create ConsumerStructureProvider and register it to listen to page events
POMSessionManager sessionManager =
(POMSessionManager)container.getComponentInstanceOfType(POMSessionManager.class);
@@ -330,7 +334,7 @@
}
catch (Exception e)
{
- throw new RuntimeException("Couldn't start WSRP consumers
registry.", e);
+ throw new RuntimeException("Couldn't start WSRP consumers registry from
configuration " + consumersConfigLocation, e);
}
container.registerComponentInstance(ConsumerRegistry.class, consumerRegistry);
@@ -398,4 +402,4 @@
}
}
-}
\ No newline at end of file
+}
Added:
portal/trunk/wsrp-integration/extension-component/src/main/resources/conf/wsrp-consumers-config.xml
===================================================================
---
portal/trunk/wsrp-integration/extension-component/src/main/resources/conf/wsrp-consumers-config.xml
(rev 0)
+++
portal/trunk/wsrp-integration/extension-component/src/main/resources/conf/wsrp-consumers-config.xml 2011-08-25
12:22:29 UTC (rev 7233)
@@ -0,0 +1,94 @@
+<?xml version='1.0' encoding='UTF-8' ?>
+
+<!--
+ ~ 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.
+ -->
+
+<deployments
xmlns="http://www.gatein.org/xml/ns/gatein_wsrp_consumer_1_0"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://www.gatein.org/xml/ns/gatein_wsrp_consume...
http://www.jboss.org/portal/xsd/gatein_wsrp_consumer_1_0.xsd">
+ <deployment>
+ <wsrp-producer id="selfv1" expiration-cache="500"
ws-timeout="50000">
+
<endpoint-wsdl-url>http://localhost:8080/wsrp-producer/v1/MarkupService?wsdl</endpoint-wsdl-url>
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>
+ <deployment>
+ <wsrp-producer id="selfv2" expiration-cache="500"
ws-timeout="50000">
+
<endpoint-wsdl-url>http://localhost:8080/wsrp-producer/v2/MarkupService?wsdl</endpoint-wsdl-url>
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>
+ <!--<deployment>
+ <wsrp-producer id="NetUnity" expiration-cache="300">
+
<
endpoint-wsdl-url>http://wsrp.netunitysoftware.com/WSRPTestService/WSR...
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>-->
+ <!--<deployment>
+ <wsrp-producer id="NetUnityV2" expiration-cache="300">
+
<
endpoint-wsdl-url>http://www.netunitysoftware.com/wsrp2interop/WsrpPro...
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>
+ <deployment>
+ <wsrp-producer id="NetUnityV1" expiration-cache="300">
+
<
endpoint-wsdl-url>http://www.netunitysoftware.com/wsrp2interop/WsrpPro...
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>-->
+ <!--<deployment>
+ <wsrp-producer id="vignette" expiration-cache="300">
+
<endpoint-wsdl-url>http://wsrpdemo.vignette.com:8080/producer/wsdl</endpoint-wsdl-url>
+ <registration-data>
+ <property>
+ <name>com.vignette.wsrp.registration.username</name>
+ <lang>en</lang>
+ <value>test</value>
+ </property>
+ <property>
+ <name>com.vignette.wsrp.registration.password</name>
+ <lang>en</lang>
+ <value>test</value>
+ </property>
+ </registration-data>
+ </wsrp-producer>
+ </deployment>-->
+ <!--<deployment>
+ <wsrp-producer id="bea" expiration-cache="300">
+
<endpoint-wsdl-url>http://wsrp.bea.com:7001/producer/producer?WSDL</endpoint-wsdl-url>
+ <registration-data>
+ <property>
+ <name>{urn:bea:wlp:prop:reg:registration}consumerRole</name>
+ <lang>en</lang>
+ <value>insider</value>
+ </property>
+ </registration-data>
+ </wsrp-producer>
+ </deployment>-->
+ <!--<deployment>
+ <wsrp-producer id="oracle" expiration-cache="300">
+
<
endpoint-wsdl-url>http://portalstandards.oracle.com/portletapp/portlet...
+ <registration-data/>
+ </wsrp-producer>
+ </deployment>-->
+</deployments>
\ No newline at end of file
Property changes on:
portal/trunk/wsrp-integration/extension-component/src/main/resources/conf/wsrp-consumers-config.xml
___________________________________________________________________
Added: svn:executable
+ *