Author: mwringe
Date: 2009-04-20 13:43:21 -0400 (Mon, 20 Apr 2009)
New Revision: 13236
Added:
modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-consumer_2_6.dtd
modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-producer_2_6.dtd
modules/deployer/trunk/deployer/src/main/deployer/xsd/
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-consumer_2_6.xsd
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_6.xsd
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_7.xsd
modules/deployer/trunk/wsrp/
modules/deployer/trunk/wsrp/pom.xml
modules/deployer/trunk/wsrp/src/
modules/deployer/trunk/wsrp/src/main/
modules/deployer/trunk/wsrp/src/main/java/
modules/deployer/trunk/wsrp/src/main/java/org/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDependencyDeployer.java
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDeployer.java
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/container/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/container/WSRPDeployment.java
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPConsumerParser.java
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPProducerParser.java
modules/deployer/trunk/wsrp/src/test/
modules/deployer/trunk/wsrp/src/test/java/
Modified:
modules/deployer/trunk/.classpath
modules/deployer/trunk/build/pom.xml
modules/deployer/trunk/deployer/pom.xml
modules/deployer/trunk/deployer/src/assemble/jboss-portal-deployer.xml
modules/deployer/trunk/deployer/src/main/deployer/META-INF/deployer-jboss-beans.xml
modules/deployer/trunk/pom.xml
Log:
Add wsrp deployers.
Modified: modules/deployer/trunk/.classpath
===================================================================
--- modules/deployer/trunk/.classpath 2009-04-20 17:40:51 UTC (rev 13235)
+++ modules/deployer/trunk/.classpath 2009-04-20 17:43:21 UTC (rev 13236)
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="theme/src/main/java"/>
+ <classpathentry kind="src" path="wsrp/src/main/java"/>
+ <classpathentry kind="src" path="wsrp/src/test/java"/>
<classpathentry kind="src" path="theme/src/test/java"/>
<classpathentry kind="src" path="portal/src/main/java"/>
<classpathentry kind="src" path="portlet/src/main/java"/>
Modified: modules/deployer/trunk/build/pom.xml
===================================================================
--- modules/deployer/trunk/build/pom.xml 2009-04-20 17:40:51 UTC (rev 13235)
+++ modules/deployer/trunk/build/pom.xml 2009-04-20 17:43:21 UTC (rev 13236)
@@ -17,7 +17,7 @@
<version.assembly>2.2-beta-2</version.assembly>
<version.jboss.aop>1.0.0.GA</version.jboss.aop>
<version.jboss.aspects>1.0.0.GA</version.jboss.aspects>
- <version.jboss-deployers>2.2.0-SNAPSHOT</version.jboss-deployers>
+ <version.jboss-deployers>2.0.5.GA</version.jboss-deployers>
<version.jboss-metadata>1.0.0.CR1</version.jboss-metadata>
<version.jboss.portal>2.8-SNAPSHOT</version.jboss.portal>
<version.jboss.portal.metadata>trunk-SNAPSHOT</version.jboss.portal.metadata>
@@ -98,6 +98,11 @@
<artifactId>metadata-theme</artifactId>
<version>${version.jboss.portal.metadata}</version>
</dependency>
+ <dependency>
+ <groupId>org.jboss.portal.metadata</groupId>
+ <artifactId>metadata-wsrp</artifactId>
+ <version>${version.jboss.portal.metadata}</version>
+ </dependency>
<dependency>
<groupId>org.jboss.maven.plugins</groupId>
Modified: modules/deployer/trunk/deployer/pom.xml
===================================================================
--- modules/deployer/trunk/deployer/pom.xml 2009-04-20 17:40:51 UTC (rev 13235)
+++ modules/deployer/trunk/deployer/pom.xml 2009-04-20 17:43:21 UTC (rev 13236)
@@ -28,6 +28,11 @@
<version>${project.version}</version>
</dependency>
<dependency>
+ <groupId>org.jboss.portal.deployer</groupId>
+ <artifactId>deployer-wsrp</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
<groupId>org.jboss.portal.metadata</groupId>
<artifactId>metadata-metadata</artifactId>
</dependency>
@@ -35,6 +40,10 @@
<groupId>org.jboss.portal.metadata</groupId>
<artifactId>metadata-theme</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.jboss.portal.metadata</groupId>
+ <artifactId>metadata-wsrp</artifactId>
+ </dependency>
</dependencies>
<build>
Modified: modules/deployer/trunk/deployer/src/assemble/jboss-portal-deployer.xml
===================================================================
--- modules/deployer/trunk/deployer/src/assemble/jboss-portal-deployer.xml 2009-04-20
17:40:51 UTC (rev 13235)
+++ modules/deployer/trunk/deployer/src/assemble/jboss-portal-deployer.xml 2009-04-20
17:43:21 UTC (rev 13236)
@@ -17,8 +17,10 @@
<include>org.jboss.portal.deployer:deployer-portal</include>
<include>org.jboss.portal.deployer:deployer-portlet</include>
<include>org.jboss.portal.deployer:deployer-theme</include>
+ <include>org.jboss.portal.deployer:deployer-wsrp</include>
<include>org.jboss.portal.metadata:metadata-metadata</include>
<include>org.jboss.portal.metadata:metadata-theme</include>
+ <include>org.jboss.portal.metadata:metadata-wsrp</include>
</includes>
</dependencySet>
<dependencySet>
Modified:
modules/deployer/trunk/deployer/src/main/deployer/META-INF/deployer-jboss-beans.xml
===================================================================
---
modules/deployer/trunk/deployer/src/main/deployer/META-INF/deployer-jboss-beans.xml 2009-04-20
17:40:51 UTC (rev 13235)
+++
modules/deployer/trunk/deployer/src/main/deployer/META-INF/deployer-jboss-beans.xml 2009-04-20
17:43:21 UTC (rev 13236)
@@ -46,6 +46,14 @@
<key>-//JBoss Portal//DTD JBoss Portal RenderSet 2.8//EN</key>
<value>dtd/portal-rendersets_2_7.dtd</value>
</entry>
+ <entry>
+ <key>-//JBoss Portal//DTD JBoss Portal WSRP Consumer
2.6//EN</key>
+ <value>dtd/jboss-wsrp-consumer_2_6.dtd</value>
+ </entry>
+ <entry>
+ <key>-//JBoss Portal//DTD JBoss Portal WSRP Producer
2.6//EN</key>
+ <value>dtd/jboss-wsrp-producer_2_6.dtd</value>
+ </entry>
</map>
</property>
</bean>
@@ -94,6 +102,18 @@
<key>portal-renderset_2_7.dtd</key>
<value>org.jboss.portal.metadata.renderset.PortalRenderSetsMetaData</value>
</entry>
+ <entry>
+ <key>jboss-wsrp-producer_2_6.dtd</key>
+
<value>org.jboss.portal.metadata.wsrp.consumer.ConsumerDeploymentsMetaData</value>
+ </entry>
+ <entry>
+ <key>jboss-wsrp-consumer_2_6.dtd</key>
+
<value>org.jboss.portal.metadata.wsrp.producer.ProducerConfiguration26MetaData</value>
+ </entry>
+ <entry>
+ <key>producer-configuration</key>
+
<value>org.jboss.portal.metadata.wsrp.producer.ProducerConfiguration26MetaData</value>
+ </entry>
</map>
</property>
<property name="XSDMapping">
@@ -106,6 +126,18 @@
<
key>http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd</key>
<value>org.jboss.portal.metadata.portlet.mc.AnnotationPortletApplication20MetaData</value>
</entry>
+ <entry>
+ <key>urn:jboss:portal:wsrp:consumer:v2_6</key>
+
<value>org.jboss.portal.metadata.wsrp.consumer.AnnotatedConsumerDeploymentsMetaData</value>
+ </entry>
+ <entry>
+ <key>urn:jboss:portal:wsrp:producer:v2_6</key>
+
<value>org.jboss.portal.metadata.wsrp.producer.AnnotatedProducerConfiguration26MetaData</value>
+ </entry>
+ <entry>
+ <key>urn:jboss:portal:wsrp:producer:v2_7</key>
+
<value>org.jboss.portal.metadata.wsrp.producer.AnnotatedProducerConfiguration27MetaData</value>
+ </entry>
</map>
</property>
</bean>
@@ -149,10 +181,16 @@
<!-- *-renderSet.xml parsing -->
<bean name="PortalRenderSetParsingDeployer"
class="org.jboss.portal.deployer.theme.parsing.PortalRenderSetParsingDeployer"/>
+ <!-- *-wsrp.xml parsing -->
+ <bean name="WSRPConsumerParsingDeployer"
class="org.jboss.portal.deployer.wsrp.parsing.WSRPConsumerParser"/>
+
+ <bean name="WSRPProducerParsingDeployer"
class="org.jboss.portal.deployer.wsrp.parsing.WSRPProducerParser"/>
+
<bean name="MergedPortletParsingDeployer"
class="org.jboss.portal.deployer.parsing.MergedPortletParsingDeployer">
<property
name="standardPortletFileLocation">conf/standardjboss-portlet.xml</property>
</bean>
+
<!-- component deployables -->
<!--
where the actual deployment occurs, these classes will send the data to the various
runtime containers
@@ -205,5 +243,16 @@
<property name="MBeanServer"><inject
bean="JMXKernel" property="mbeanServer"/></property>
<property name="TLDDirectory">tld</property>
</bean>
+
+ <bean name="WSRPConsumerDeployer"
class="org.jboss.portal.deployer.wsrp.WSRPConsumerDeployer">
+ </bean>
+
+ <bean name="WSRPDependencyDeployer"
class="org.jboss.portal.deployer.wsrp.WSRPConsumerDependencyDeployer">
+ <property name="dependencies">
+ <list elementClass="java.lang.String">
+ <value>portal.wsrp:service=WSRPDeploymentImpl</value>
+ </list>
+ </property>
+ </bean>
</deployment>
Added: modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-consumer_2_6.dtd
===================================================================
--- modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-consumer_2_6.dtd
(rev 0)
+++
modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-consumer_2_6.dtd 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,85 @@
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ 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 Portal's WSRP Remote Producer Configuration deployment descriptor for the
*-wsrp.xml files used by Portal to be
+able to consume WSRP portlets exposed by a remote producer.
+author: <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+version: 1.1 (Portal 2.6)
+revision: $Revision: 8784 $
+-->
+
+<!-- The root element. Contains deployment elements. -->
+<!ELEMENT deployments ( deployment* )>
+
+<!-- Deployment related information. As of Portal 2.6, the only deployment information
relates to WSRP remote producers. -->
+<!ELEMENT deployment ( wsrp-producer )>
+
+<!-- Information on a remote WSRP producer identified by the mandatory producer-id
attribute. -->
+<!ELEMENT wsrp-producer ( ( endpoint-config | endpoint-wsdl-url ), registration-data?
)>
+
+<!-- The producer identifier. This should be unique for a given Portal deployment. The
identifier is used to
+identify the portlet provider in the management interface. -->
+<!ATTLIST wsrp-producer id CDATA #REQUIRED>
+
+<!-- The period of producer information (such as list of offered portlets) cache
refreshing in seconds. -->
+<!ATTLIST wsrp-producer expiration-cache CDATA #IMPLIED>
+
+<!-- WSRP endpoints configuration information by interface URL. Mutually exclusive
with endpoint-wsdl-url. -->
+<!ELEMENT endpoint-config ( service-description-url, markup-url, registration-url?,
portlet-management-url? )>
+
+<!-- The URL for the service description interface endpoint on the remote producer.
-->
+<!ELEMENT service-description-url ( #PCDATA )>
+
+<!-- The URL for the markup interface endpoint on the remote producer. -->
+<!ELEMENT markup-url ( #PCDATA )>
+
+<!-- The URL for the optional portlet management interface endpoint on the remote
producer. -->
+<!ELEMENT portlet-management-url ( #PCDATA )>
+
+<!-- The URL for the optional registration interface endpoint on the remote producer.
-->
+<!ELEMENT registration-url ( #PCDATA )>
+
+<!-- The URL of the WSDL description of the producer's WSRP services. Mutally
exclusive with endpoint-config. -->
+<!ELEMENT endpoint-wsdl-url ( #PCDATA )>
+
+<!-- Container for registration information. -->
+<!ELEMENT registration-data ( consumer-name?, property* )>
+
+<!--
+An optional name (preferably unique) that identifies the Consumer. An example of such a
name would be the Consumer's URL.
+If no consumer-name is provided, one will be automatically generated by JBoss Portal.
+-->
+<!ELEMENT consumer-name ( #PCDATA )>
+
+<!-- A registration property. -->
+<!ELEMENT property ( name, lang, value )>
+
+<!-- The name of the property. -->
+<!ELEMENT name ( #PCDATA )>
+
+<!-- The language the property is in. -->
+<!ELEMENT lang ( #PCDATA )>
+
+<!-- The value of the property. -->
+<!ELEMENT value ( #PCDATA )>
\ No newline at end of file
Added: modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-producer_2_6.dtd
===================================================================
--- modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-producer_2_6.dtd
(rev 0)
+++
modules/deployer/trunk/deployer/src/main/deployer/dtd/jboss-wsrp-producer_2_6.dtd 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,87 @@
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<!--
+A DTD for the configuration of Portal's WSRP producer.
+
+author: <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+version: 1.0 (Portal 2.6)
+revision: $Revision: 8784 $
+-->
+
+<!-- Root element for the producer configuration. Contains a single
registration-configuration as of Portal 2.6 -->
+<!ELEMENT producer-configuration ( registration-configuration? )>
+
+
+<!-- Allows configuration of whether the producer requires registration or not and how
to deal with registrations. -->
+<!ELEMENT registration-configuration ( (registration-property-validator |
registration-policy)?, registration-property-description* )>
+
+<!--
+Specifies whether the producer will send a complete service description (that is one
including offered portlets) or not
+to unregistered consumers.
+-->
+<!ATTLIST registration-configuration fullServiceDescriptionRequiresRegistration (true
| false) "false">
+
+<!--
+A fully-qualified class name for a class implementing the RegistrationPropertyValidator
interface. Only makes sense when
+using the default RegistrationPolicy.
+-->
+<!ELEMENT registration-property-validator ( #PCDATA )>
+
+<!--
+A fully-qualified class name for an implementation of the RegistrationPolicy interface,
allowing users to customize
+the behavior of the producer when handling registration attempts.
+ -->
+<!ELEMENT registration-policy ( #PCDATA )>
+
+<!--
+The description for a registration property for which the producer will require consumers
to provide a value.
+Example:
+<registration-property-description>
+ <name>name1</name>
+ <type>xsd:string</type>
+ <label xml:lang="en"
resourceName="resource.label1">label1</label>
+ <hint xml:lang="en"
resourceName="resource.hint1">hint1</hint>
+</registration-property-description>
+-->
+<!ELEMENT registration-property-description ( name, type, label, hint? )>
+
+<!-- The name of the registration property -->
+<!ELEMENT name ( #PCDATA )>
+
+<!-- The qualified name of the type of the registration property. As of Portal 2.6,
only xsd:string is supported. -->
+<!ELEMENT type ( #PCDATA )>
+
+<!-- A description of the registration property and its usage targeted at end users.
-->
+<!ELEMENT hint ( #PCDATA )>
+<!-- The language in which the hint is written. -->
+<!ATTLIST hint xml:lang CDATA #REQUIRED>
+<!-- A resource name identifying the hint in localization bundles (currently
unsupported in Portal 2.6). -->
+<!ATTLIST hint resourceName CDATA #IMPLIED>
+
+<!-- A short, human readable name for the property, intended for consumer-generated
administration interface. -->
+<!ELEMENT label ( #PCDATA )>
+<!-- The language in which the label is written. -->
+<!ATTLIST label xml:lang CDATA #REQUIRED>
+<!-- A resource name identifying the label in localization bundles (currently
unsupported in Portal 2.6). -->
+<!ATTLIST label resourceName CDATA #IMPLIED>
Added: modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-consumer_2_6.xsd
===================================================================
--- modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-consumer_2_6.xsd
(rev 0)
+++
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-consumer_2_6.xsd 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,194 @@
+<?xml version="1.0"?>
+
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2007, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="urn:jboss:portal:wsrp:consumer:v2_6"
+ xmlns="urn:jboss:portal:wsrp:consumer:v2_6"
+
xmlns:xml="http://www.w3.org/XML/1998/namespace"
+ xmlns:wcc="urn:jboss:portal:wsrp:consumer:v2_6"
+ elementFormDefault="qualified">
+
+ <xs:import
namespace="http://www.w3.org/XML/1998/namespace"/>
+
+ <xs:element name="deployments">
+ <xs:annotation>
+ <xs:documentation>Root element. Contains deployment
elements.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="deployment" type="wcc:Deployment"
minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:complexType name="Deployment">
+ <xs:annotation>
+ <xs:documentation>Deployment related information. As of Portal 2.6, the
only deployment information relates to
+ WSRP remote producers.</xs:documentation>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="wsrp-producer" type="wcc:WSRPProducer"
maxOccurs="1" minOccurs="1"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="WSRPProducer">
+ <xs:annotation>
+ <xs:documentation>Information on a remote WSRP producer identified by the
mandatory id attribute.</xs:documentation>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:choice>
+ <xs:element name="endpoint-config"
type="wcc:EndpointConfig">
+ <xs:annotation>
+ <xs:documentation>
+ WSRP endpoints configuration information by interface URL. Mutually exclusive
with endpoint-wsdl-url.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="endpoint-wsdl-url"
type="xs:anyURI">
+ <xs:annotation>
+ <xs:documentation>
+ The URL of the WSDL description of the producer's WSRP services. Mutally
exclusive with endpoint-config.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:choice>
+ <xs:element name="registration-data"
type="wcc:RegistrationData" minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>
+ Container for registration information.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="id" type="xs:string"
use="required">
+ <xs:annotation>
+ <xs:documentation>
+ The producer identifier. This should be unique for a given Portal
deployment. The identifier is used to
+ identify the portlet provider in the management interface.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="expiration-cache" type="wcc:cacheValue"
use="required">
+ <xs:annotation>
+ <xs:documentation>The period of producer information (such as list of
offered portlets) cache refreshing in seconds.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+
+ <xs:simpleType name="cacheValue" id="cacheValue">
+ <xs:annotation>
+ <xs:documentation>
+ Type for cache information. Positive or null integer, allowing -1 as a value to
indicate that cache should not
+ be used.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:restriction base="xs:integer">
+ <xs:minInclusive value="-1"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:complexType name="EndpointConfig">
+ <xs:sequence>
+ <xs:element name="service-description-url"
type="xs:anyURI">
+ <xs:annotation>
+ <xs:documentation>
+ The mandatory URL for the service description interface endpoint on the
remote producer.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="markup-url" type="xs:anyURI">
+ <xs:annotation>
+ <xs:documentation>
+ The madatory URL for the markup interface endpoint on the remote
producer.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="registration-url" type="xs:anyURI"
minOccurs="0" maxOccurs="1">
+ <xs:annotation>
+ <xs:documentation>
+ The optional URL for the registration interface endpoint on the remote
producer.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="portlet-management-url"
type="xs:anyURI" minOccurs="0" maxOccurs="1">
+ <xs:annotation>
+ <xs:documentation>
+ The optional URL for the portlet management interface endpoint on the
remote producer.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="RegistrationData">
+ <xs:sequence>
+ <xs:element name="consumer-name" type="xs:string"
minOccurs="0" maxOccurs="1">
+ <xs:annotation>
+ <xs:documentation>
+ An optional name (preferably unique) that identifies the Consumer. An
example of such a name would be
+ the Consumer's URL. If no consumer-name is provided, one will be
automatically generated by JBoss Portal.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="property" type="wcc:Property"
minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>
+ Optional registration properties required by the remote producer.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="Property">
+ <xs:annotation>
+ <xs:documentation>
+ Registration property.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="name" type="xs:string">
+ <xs:annotation>
+ <xs:documentation>
+ Name of the property.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="lang" type="xs:language">
+ <xs:annotation>
+ <xs:documentation>
+ Language the property is in.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="value" type="xs:string">
+ <xs:annotation>
+ <xs:documentation>
+ Value of the property.
+ </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+</xs:schema>
Added: modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_6.xsd
===================================================================
--- modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_6.xsd
(rev 0)
+++
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_6.xsd 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,68 @@
+<?xml version="1.0"?>
+
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2007, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="urn:jboss:portal:wsrp:producer:v2_6"
+ xmlns="urn:jboss:portal:wsrp:producer:v2_6"
+
xmlns:xml="http://www.w3.org/XML/1998/namespace"
+ xmlns:wpc="urn:jboss:portal:wsrp:producer:v2_6"
elementFormDefault="qualified">
+
+ <xs:import
namespace="http://www.w3.org/XML/1998/namespace"/>
+
+ <xs:element name="producer-configuration">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="registration-configuration"
type="wpc:RegistrationConfiguration"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:complexType name="RegistrationConfiguration">
+ <xs:sequence>
+ <xs:element name="registration-policy" type="xs:string"
minOccurs="0"/>
+ <xs:element name="registration-property-validator"
type="xs:string" minOccurs="0"/>
+ <xs:element name="registration-property-description"
type="wpc:RegistrationPropertyDescription" minOccurs="0"
+ maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="fullServiceDescriptionRequiresRegistration"
type="xs:boolean" use="optional"/>
+ </xs:complexType>
+
+ <xs:complexType name="RegistrationPropertyDescription">
+ <xs:sequence>
+ <xs:element name="name" type="xs:QName"/>
+ <xs:element name="type" type="xs:QName"/>
+ <xs:element name="label" type="wpc:LocalizedString"
minOccurs="0"/>
+ <xs:element name="hint" type="wpc:LocalizedString"
minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="LocalizedString">
+ <xs:simpleContent>
+ <xs:extension base="xs:string">
+ <xs:attribute ref="xml:lang" use="required"/>
+ <xs:attribute name="resourceName" type="xs:string"
use="optional"/>
+ </xs:extension>
+ </xs:simpleContent>
+ </xs:complexType>
+</xs:schema>
Added: modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_7.xsd
===================================================================
--- modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_7.xsd
(rev 0)
+++
modules/deployer/trunk/deployer/src/main/deployer/xsd/jboss-wsrp-producer_2_7.xsd 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="urn:jboss:portal:wsrp:producer:v2_7"
+ xmlns="urn:jboss:portal:wsrp:producer:v2_7"
+
xmlns:xml="http://www.w3.org/XML/1998/namespace"
+ xmlns:wpc="urn:jboss:portal:wsrp:producer:v2_7"
elementFormDefault="qualified">
+
+ <xs:import
namespace="http://www.w3.org/XML/1998/namespace"/>
+
+ <xs:element name="producer-configuration">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="registration-configuration"
type="wpc:RegistrationConfiguration"/>
+ </xs:sequence>
+ <xs:attribute name="useStrictMode" type="xs:boolean"
use="optional"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:complexType name="RegistrationConfiguration">
+ <xs:sequence>
+ <xs:element name="registration-policy" type="xs:string"
minOccurs="0"/>
+ <xs:element name="registration-property-validator"
type="xs:string" minOccurs="0"/>
+ <xs:element name="registration-property-description"
type="wpc:RegistrationPropertyDescription" minOccurs="0"
+ maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="fullServiceDescriptionRequiresRegistration"
type="xs:boolean" use="optional"/>
+ </xs:complexType>
+
+ <xs:complexType name="RegistrationPropertyDescription">
+ <xs:sequence>
+ <xs:element name="name" type="xs:QName"/>
+ <xs:element name="type" type="xs:QName"/>
+ <xs:element name="label" type="wpc:LocalizedString"
minOccurs="0"/>
+ <xs:element name="hint" type="wpc:LocalizedString"
minOccurs="0"/>
+ <xs:element name="description" type="wpc:LocalizedString"
minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="LocalizedString">
+ <xs:simpleContent>
+ <xs:extension base="xs:string">
+ <xs:attribute ref="xml:lang" use="required"/>
+ <xs:attribute name="resourceName" type="xs:string"
use="optional"/>
+ </xs:extension>
+ </xs:simpleContent>
+ </xs:complexType>
+</xs:schema>
Modified: modules/deployer/trunk/pom.xml
===================================================================
--- modules/deployer/trunk/pom.xml 2009-04-20 17:40:51 UTC (rev 13235)
+++ modules/deployer/trunk/pom.xml 2009-04-20 17:43:21 UTC (rev 13236)
@@ -27,6 +27,7 @@
<module>portal</module>
<module>portlet</module>
<module>theme</module>
+ <module>wsrp</module>
<module>deployer</module>
</modules>
Added: modules/deployer/trunk/wsrp/pom.xml
===================================================================
--- modules/deployer/trunk/wsrp/pom.xml (rev 0)
+++ modules/deployer/trunk/wsrp/pom.xml 2009-04-20 17:43:21 UTC (rev 13236)
@@ -0,0 +1,98 @@
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.jboss.portal.deployer</groupId>
+ <artifactId>module-parent</artifactId>
+ <version>trunk-SNAPSHOT</version>
+ <relativePath>../build/pom.xml</relativePath>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>deployer-wsrp</artifactId>
+ <packaging>jar</packaging>
+ <name>JBoss Portal Modules WSRP Deployer</name>
+
+ <dependencies>
+
+ <dependency>
+ <groupId>org.jboss.deployers</groupId>
+ <artifactId>jboss-deployers-spi</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.deployers</groupId>
+ <artifactId>jboss-deployers-vfs</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.metadata</groupId>
+ <artifactId>jboss-metadata</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbossas</groupId>
+ <artifactId>jboss-as-server</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>saxon</groupId>
+ <artifactId>saxon</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.portal.deployer</groupId>
+ <artifactId>deployer-portal</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.portal.deployer</groupId>
+ <artifactId>deployer-portlet</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.portal.metadata</groupId>
+ <artifactId>metadata-metadata</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.portal.metadata</groupId>
+ <artifactId>metadata-wsrp</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.jboss.aspects</groupId>
+ <artifactId>jboss-security-aspects</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.aspects</groupId>
+ <artifactId>jboss-transaction-aspects</artifactId>
+ <scope>provided</scope>
+ </dependency>
+
+ </dependencies>
+
+ <build>
+
+<pluginManagement>
+<plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ <version>2.2</version>
+</plugin>
+</plugins>
+</pluginManagement>
+
+ <plugins>
+
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <encoding>iso-8859-1</encoding>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+
+ </plugins>
+ </build>
+</project>
Added:
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDependencyDeployer.java
===================================================================
---
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDependencyDeployer.java
(rev 0)
+++
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDependencyDeployer.java 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,86 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2009, 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. *
+ ******************************************************************************/
+package org.jboss.portal.deployer.wsrp;
+
+import java.util.ArrayList;
+
+import org.jboss.dependency.plugins.AbstractDependencyItem;
+import org.jboss.dependency.spi.ControllerContext;
+import org.jboss.dependency.spi.ControllerState;
+import org.jboss.dependency.spi.DependencyItem;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentStages;
+import org.jboss.deployers.spi.deployer.helpers.AbstractDeployer;
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.portal.metadata.wsrp.consumer.ConsumerDeploymentsMetaData;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class WSRPConsumerDependencyDeployer extends AbstractDeployer
+{
+
+ protected ArrayList<String> dependencies;
+
+ public static final String WSRP_DEPENDENCIES_ADDED =
"wsrp.dependencies.added";
+
+ public WSRPConsumerDependencyDeployer()
+ {
+ this.setAllInputs(false);
+ this.setInput(ConsumerDeploymentsMetaData.class);
+ this.addOutput(WSRP_DEPENDENCIES_ADDED);
+ this.setStage(DeploymentStages.POST_PARSE);
+ }
+
+ public void setDependencies(ArrayList<String> dependencies)
+ {
+ this.dependencies = dependencies;
+ }
+
+ public void deploy(DeploymentUnit unit) throws DeploymentException
+ {
+ ControllerContext context = unit.getAttachment(ControllerContext.class);
+
+ if (context != null)
+ {
+
+ if (dependencies != null)
+ {
+ for (int i = 0; i < dependencies.size(); i++)
+ {
+ String dependency = dependencies.get(i);
+
+ // the controller state must be set to Real to make sure that the
deployable is not initalized before the dependencies.
+ // TODO: use ControllerState.REAL if it gets added as an option to the
ControllerState class.
+ DependencyItem dependItem = new AbstractDependencyItem(context.getName(),
dependency,
+ new ControllerState("Real"), ControllerState.CREATE);
+
+ unit.addIDependOn(dependItem);
+ }
+ }
+ }
+ }
+
+}
+
Added:
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDeployer.java
===================================================================
---
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDeployer.java
(rev 0)
+++
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/WSRPConsumerDeployer.java 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,67 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2009, 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. *
+ ******************************************************************************/
+package org.jboss.portal.deployer.wsrp;
+
+import org.jboss.beans.metadata.api.annotations.Install;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentStages;
+import org.jboss.deployers.spi.deployer.helpers.AbstractComponentDeployer;
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.portal.deployer.portlet.PortletDeployer;
+import org.jboss.portal.deployer.wsrp.container.WSRPDeployment;
+import org.jboss.portal.metadata.wsrp.consumer.ConsumerDeploymentsMetaData;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class WSRPConsumerDeployer extends AbstractComponentDeployer
+{
+
+ WSRPDeployment deployment;
+
+ public WSRPConsumerDeployer()
+ {
+ this.setAllInputs(false);
+ this.setInput(ConsumerDeploymentsMetaData.class);
+ this.addInput(PortletDeployer.PORLET_DEPLOYED);
+ this.addInput(WSRPConsumerDependencyDeployer.WSRP_DEPENDENCIES_ADDED);
+ this.setStage(DeploymentStages.INSTALLED);
+ }
+
+ @Install
+ public void addDeployment(WSRPDeployment deployment)
+ {
+ this.deployment = deployment;
+ }
+
+ @Override
+ public void internalDeploy(DeploymentUnit unit) throws DeploymentException
+ {
+ ConsumerDeploymentsMetaData deployments =
unit.getAttachment(ConsumerDeploymentsMetaData.class);
+
+ deployment.deployConsumer(deployments);
+ }
+
+}
+
Added:
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/container/WSRPDeployment.java
===================================================================
---
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/container/WSRPDeployment.java
(rev 0)
+++
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/container/WSRPDeployment.java 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,36 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2009, 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. *
+ ******************************************************************************/
+package org.jboss.portal.deployer.wsrp.container;
+
+import org.jboss.portal.metadata.wsrp.consumer.ConsumerDeploymentsMetaData;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public interface WSRPDeployment
+{
+ public void deployConsumer (ConsumerDeploymentsMetaData deployments);
+
+}
+
Added:
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPConsumerParser.java
===================================================================
---
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPConsumerParser.java
(rev 0)
+++
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPConsumerParser.java 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,64 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2009, 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. *
+ ******************************************************************************/
+package org.jboss.portal.deployer.wsrp.parsing;
+
+import org.jboss.deployers.vfs.spi.structure.VFSDeploymentUnit;
+import org.jboss.portal.deployer.parsing.PortalResolverDeployer;
+import org.jboss.portal.metadata.wsrp.consumer.ConsumerDeploymentsMetaData;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class WSRPConsumerParser extends
PortalResolverDeployer<ConsumerDeploymentsMetaData>
+{
+
+ public WSRPConsumerParser()
+ {
+ super(ConsumerDeploymentsMetaData.class);
+ this.setSuffix("-wsrp.xml");
+ // relative order obtained from the old WSRPDeployer class
+ // TODO: figure out if this is actually needed.
+ this.setRelativeOrder(800);
+ }
+
+ public void setXmlPath(String xmlPath)
+ {
+ this.setName(xmlPath);
+ }
+
+ public String getXmlPath()
+ {
+ return getName();
+ }
+
+ protected ConsumerDeploymentsMetaData parse(VFSDeploymentUnit unit, VirtualFile file,
ConsumerDeploymentsMetaData root)
+ throws Exception
+ {
+ ConsumerDeploymentsMetaData consumerDeployments = (ConsumerDeploymentsMetaData)
super.parse(unit, file, root);
+ return consumerDeployments;
+ }
+
+}
+
Added:
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPProducerParser.java
===================================================================
---
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPProducerParser.java
(rev 0)
+++
modules/deployer/trunk/wsrp/src/main/java/org/jboss/portal/deployer/wsrp/parsing/WSRPProducerParser.java 2009-04-20
17:43:21 UTC (rev 13236)
@@ -0,0 +1,61 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2009, 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. *
+ ******************************************************************************/
+package org.jboss.portal.deployer.wsrp.parsing;
+
+import org.jboss.deployers.vfs.spi.structure.VFSDeploymentUnit;
+import org.jboss.portal.deployer.parsing.PortalResolverDeployer;
+import org.jboss.portal.metadata.wsrp.producer.ProducerConfiguration26MetaData;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class WSRPProducerParser extends
PortalResolverDeployer<ProducerConfiguration26MetaData>
+{
+
+ public WSRPProducerParser()
+ {
+ super(ProducerConfiguration26MetaData.class);
+ this.setName("conf/producer/config.xml");
+ }
+
+ public void setXmlPath(String xmlPath)
+ {
+ this.setName(xmlPath);
+ }
+
+ public String getXmlPath()
+ {
+ return getName();
+ }
+
+ protected ProducerConfiguration26MetaData parse(VFSDeploymentUnit unit, VirtualFile
file, ProducerConfiguration26MetaData root)
+ throws Exception
+ {
+ ProducerConfiguration26MetaData producerConfiguration =
(ProducerConfiguration26MetaData) super.parse(unit, file, root);
+ return producerConfiguration;
+ }
+
+}
+