gatein SVN: r5865 - portal/branches/branch-GTNPORTAL-1790/webui/portal/src/main/java/org/exoplatform/portal/application.
by do-not-reply@jboss.org
Author: ndkhoiits
Date: 2011-02-10 03:02:14 -0500 (Thu, 10 Feb 2011)
New Revision: 5865
Modified:
portal/branches/branch-GTNPORTAL-1790/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java
Log:
GTNPORTAL-1753 The header will be duplicated if contains a portlet adding more one resource to header
Modified: portal/branches/branch-GTNPORTAL-1790/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java
===================================================================
--- portal/branches/branch-GTNPORTAL-1790/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java 2011-02-10 04:59:33 UTC (rev 5864)
+++ portal/branches/branch-GTNPORTAL-1790/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java 2011-02-10 08:02:14 UTC (rev 5865)
@@ -450,9 +450,9 @@
List<String> markupHeaders = new ArrayList<String>();
if (extraMarkupHeaders != null && !extraMarkupHeaders.isEmpty())
{
- StringWriter sw = new StringWriter();
for (Element element : extraMarkupHeaders)
{
+ StringWriter sw = new StringWriter();
DOMSerializer.serialize(element, sw);
markupHeaders.add(sw.toString());
}
13 years, 10 months
gatein SVN: r5864 - portal/branches.
by do-not-reply@jboss.org
Author: ndkhoiits
Date: 2011-02-09 23:59:33 -0500 (Wed, 09 Feb 2011)
New Revision: 5864
Removed:
portal/branches/branch-GTNPORTAL-1745/
Log:
GTNPORTAL-1745 Delete the commit branch of sprint 46
13 years, 10 months
gatein SVN: r5863 - portal/branches.
by do-not-reply@jboss.org
Author: ndkhoiits
Date: 2011-02-09 23:52:06 -0500 (Wed, 09 Feb 2011)
New Revision: 5863
Added:
portal/branches/branch-GTNPORTAL-1790/
Log:
GTNPORTAL-1790 Create commit branch for activities in sprint 47
Copied: portal/branches/branch-GTNPORTAL-1790 (from rev 5862, portal/trunk)
13 years, 10 months
gatein SVN: r5862 - epp/portal/branches.
by do-not-reply@jboss.org
Author: mputz
Date: 2011-02-09 11:48:35 -0500 (Wed, 09 Feb 2011)
New Revision: 5862
Added:
epp/portal/branches/EPP_5_1_0_GA_JBEPP-795/
Log:
Create patch branch for JBEPP-795 one-off patch
Copied: epp/portal/branches/EPP_5_1_0_GA_JBEPP-795 (from rev 5861, epp/portal/tags/EPP_5_1_0_GA)
13 years, 10 months
gatein SVN: r5860 - portal/branches/wsrp-extraction/component/wsrp/src/main/java/org/gatein/portal/wsrp.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2011-02-08 09:36:34 -0500 (Tue, 08 Feb 2011)
New Revision: 5860
Modified:
portal/branches/wsrp-extraction/component/wsrp/src/main/java/org/gatein/portal/wsrp/WSRPServiceIntegration.java
Log:
- Minor correction in comment.
Modified: portal/branches/wsrp-extraction/component/wsrp/src/main/java/org/gatein/portal/wsrp/WSRPServiceIntegration.java
===================================================================
--- portal/branches/wsrp-extraction/component/wsrp/src/main/java/org/gatein/portal/wsrp/WSRPServiceIntegration.java 2011-02-08 01:06:06 UTC (rev 5859)
+++ portal/branches/wsrp-extraction/component/wsrp/src/main/java/org/gatein/portal/wsrp/WSRPServiceIntegration.java 2011-02-08 14:36:34 UTC (rev 5860)
@@ -102,7 +102,7 @@
public WSRPServiceIntegration(ExoContainerContext context, InitParams params, ConfigurationManager configurationManager,
ExoKernelIntegration pc, NodeHierarchyCreator nhc) throws Exception
{
- // IMPORTANT: even though PC ExoKernelIntegration and NodeHierarchyCreator is not used anywhere in the code, it's still needed for pico
+ // IMPORTANT: even though NodeHierarchyCreator is not used anywhere in the code, it's still needed for pico
// to properly make sure that this service is started after the PC one. Yes, Pico is crap. :/
// todo: we currently only allow the service to go through initialization if we are running in the default portal
13 years, 10 months
gatein SVN: r5859 - components/wsrp/trunk.
by do-not-reply@jboss.org
Author: mwringe
Date: 2011-02-07 20:06:06 -0500 (Mon, 07 Feb 2011)
New Revision: 5859
Modified:
components/wsrp/trunk/pom.xml
Log:
GTNWSRP-123: update pom.xml which was missed in the last commit.
Modified: components/wsrp/trunk/pom.xml
===================================================================
--- components/wsrp/trunk/pom.xml 2011-02-07 22:42:15 UTC (rev 5858)
+++ components/wsrp/trunk/pom.xml 2011-02-08 01:06:06 UTC (rev 5859)
@@ -52,6 +52,7 @@
<version.gatein.wci>2.0.2-GA</version.gatein.wci>
<version.jsf>1.2_12</version.jsf>
+ <version.servlet>2.5</version.servlet>
<version.apache.commons-fileupload>1.2.1</version.apache.commons-fileupload>
<version.javax.mail>1.4.1</version.javax.mail>
<version.javax.xml.ws>2.1</version.javax.xml.ws>
@@ -133,6 +134,12 @@
</dependency>
<dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>${version.servlet}</version>
+ </dependency>
+
+ <dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>${version.apache.commons-fileupload}</version>
@@ -185,6 +192,7 @@
<module>wsrp-producer-war</module>
<module>hibernate-impl</module>
<module>jcr-impl</module>
+ <module>ws-security/jboss5</module>
</modules>
<repositories>
13 years, 10 months
gatein SVN: r5858 - in portal/branches/wsrp-extraction/packaging: jboss-as5/pkg and 1 other directories.
by do-not-reply@jboss.org
Author: mwringe
Date: 2011-02-07 17:42:15 -0500 (Mon, 07 Feb 2011)
New Revision: 5858
Added:
portal/branches/wsrp-extraction/packaging/jboss-as5/.settings/
Modified:
portal/branches/wsrp-extraction/packaging/jboss-as5/pkg/pom.xml
portal/branches/wsrp-extraction/packaging/module/src/main/javascript/portal.packaging.module.js
Log:
Add wsrp-wss-jboss5 dependency to the JBoss AS 5 buids.
Modified: portal/branches/wsrp-extraction/packaging/jboss-as5/pkg/pom.xml
===================================================================
--- portal/branches/wsrp-extraction/packaging/jboss-as5/pkg/pom.xml 2011-02-07 22:37:15 UTC (rev 5857)
+++ portal/branches/wsrp-extraction/packaging/jboss-as5/pkg/pom.xml 2011-02-07 22:42:15 UTC (rev 5858)
@@ -804,6 +804,16 @@
<artifactId>wsrp-integration-api</artifactId>
<version>${org.gatein.wsrp.version}</version>
</dependency>
+ <dependency>
+ <groupId>org.gatein.wsrp</groupId>
+ <artifactId>wsrp-jcr-impl</artifactId>
+ <version>${org.gatein.wsrp.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.wsrp</groupId>
+ <artifactId>wsrp-wss-jboss5</artifactId>
+ <version>${org.gatein.wsrp.version}</version>
+ </dependency>
<dependency>
<?context LIB?>
@@ -1095,4 +1105,4 @@
</build>
</profile>
</profiles>
-</project>
\ No newline at end of file
+</project>
Modified: portal/branches/wsrp-extraction/packaging/module/src/main/javascript/portal.packaging.module.js
===================================================================
--- portal/branches/wsrp-extraction/packaging/module/src/main/javascript/portal.packaging.module.js 2011-02-07 22:37:15 UTC (rev 5857)
+++ portal/branches/wsrp-extraction/packaging/module/src/main/javascript/portal.packaging.module.js 2011-02-07 22:42:15 UTC (rev 5858)
@@ -89,7 +89,8 @@
.addDependency(new Project("org.gatein.wsrp", "wsrp-wsrp2-ws", "jar", wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-consumer", "jar", wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-jcr-impl", "jar", wsrpVersion))
- .addDependency(new Project("org.gatein.wsrp", "wsrp-integration-api", "jar", wsrpVersion));
+ .addDependency(new Project("org.gatein.wsrp", "wsrp-integration-api", "jar", wsrpVersion))
+ .addDependency(new Project("org.gatein.wsrp", "wsrp-wss-jboss5", "jar", wsrpVersion));
module.component.scripting =
new Project("org.exoplatform.portal", "exo.portal.component.scripting", "jar", module.version).
13 years, 10 months
gatein SVN: r5857 - in components/wsrp/trunk: consumer/src/main/java/org/gatein/wsrp/services/v1 and 22 other directories.
by do-not-reply@jboss.org
Author: mwringe
Date: 2011-02-07 17:37:15 -0500 (Mon, 07 Feb 2011)
New Revision: 5857
Added:
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1MarkupPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1PortletManagementPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1RegistrationPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1ServiceDescriptionPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2MarkupPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2PortletManagementPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2RegistrationPortType.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2ServiceDescriptionPortType.java
components/wsrp/trunk/consumer/src/main/resources/org/
components/wsrp/trunk/consumer/src/main/resources/org/gatein/
components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/
components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/services/
components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/services/consumer-handler-chains.xml
components/wsrp/trunk/wsrp-producer-war/src/main/resources/
components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/
components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/
components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/
components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/endpoints/
components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/endpoints/producer-handler-chains.xml
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/jboss-web.xml
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/v1/V1MarkupService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1PortletManagementService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1RegistrationService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1ServiceDescriptionService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2MarkupService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2PortletManagementService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2RegistrationService.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2ServiceDescriptionService.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/services/SOAPServiceFactoryTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/PortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/RegistrationBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/ServiceDescriptionBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/RequestProcessor.java
components/wsrp/trunk/test/src/main/java/org/gatein/wsrp/test/support/MockHttpServletRequest.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/MarkupEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/PortletManagementEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/RegistrationEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/ServiceDescriptionEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java
Log:
GTNWSRP-123: initial support for wss. Added handler chain support via xml files, should allow for configuration of wss without modifying java files.
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 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -30,18 +30,18 @@
import org.gatein.wsrp.services.v1.V1PortletManagementService;
import org.gatein.wsrp.services.v1.V1RegistrationService;
import org.gatein.wsrp.services.v1.V1ServiceDescriptionService;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
import org.gatein.wsrp.services.v2.V2MarkupService;
import org.gatein.wsrp.services.v2.V2PortletManagementService;
import org.gatein.wsrp.services.v2.V2RegistrationService;
import org.gatein.wsrp.services.v2.V2ServiceDescriptionService;
-import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
-import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
-import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
-import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
-import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
-import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
-import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
-import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -168,25 +168,25 @@
//
String portAddress = null;
boolean isMandatoryInterface = false;
- if (WSRPV2ServiceDescriptionPortType.class.isAssignableFrom(clazz)
- || WSRPV1ServiceDescriptionPortType.class.isAssignableFrom(clazz))
+ if (V2ServiceDescriptionPortType.class.isAssignableFrom(clazz)
+ || V1ServiceDescriptionPortType.class.isAssignableFrom(clazz))
{
portAddress = serviceDescriptionURL;
isMandatoryInterface = true;
}
- else if (WSRPV2MarkupPortType.class.isAssignableFrom(clazz)
- || WSRPV1MarkupPortType.class.isAssignableFrom(clazz))
+ else if (V2MarkupPortType.class.isAssignableFrom(clazz)
+ || V1MarkupPortType.class.isAssignableFrom(clazz))
{
portAddress = markupURL;
isMandatoryInterface = true;
}
- else if (WSRPV2RegistrationPortType.class.isAssignableFrom(clazz)
- || WSRPV1RegistrationPortType.class.isAssignableFrom(clazz))
+ else if (V2RegistrationPortType.class.isAssignableFrom(clazz)
+ || V1RegistrationPortType.class.isAssignableFrom(clazz))
{
portAddress = registrationURL;
}
- else if (WSRPV2PortletManagementPortType.class.isAssignableFrom(clazz)
- || WSRPV1PortletManagementPortType.class.isAssignableFrom(clazz))
+ else if (V2PortletManagementPortType.class.isAssignableFrom(clazz)
+ || V1PortletManagementPortType.class.isAssignableFrom(clazz))
{
portAddress = portletManagementURL;
}
@@ -304,12 +304,12 @@
Class portTypeClass = null;
try
{
- portTypeClass = WSRPV2MarkupPortType.class;
- WSRPV2MarkupPortType markupPortType = wsService.getPort(WSRPV2MarkupPortType.class);
+ portTypeClass = V2MarkupPortType.class;
+ V2MarkupPortType markupPortType = wsService.getPort(V2MarkupPortType.class);
markupURL = (String)((BindingProvider)markupPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
- portTypeClass = WSRPV2ServiceDescriptionPortType.class;
- WSRPV2ServiceDescriptionPortType sdPort = wsService.getPort(WSRPV2ServiceDescriptionPortType.class);
+ portTypeClass = V2ServiceDescriptionPortType.class;
+ V2ServiceDescriptionPortType sdPort = wsService.getPort(V2ServiceDescriptionPortType.class);
serviceDescriptionURL = (String)((BindingProvider)sdPort).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -321,7 +321,7 @@
try
{
- WSRPV2PortletManagementPortType managementPortType = wsService.getPort(WSRPV2PortletManagementPortType.class);
+ V2PortletManagementPortType managementPortType = wsService.getPort(V2PortletManagementPortType.class);
portletManagementURL = (String)((BindingProvider)managementPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -332,7 +332,7 @@
try
{
- WSRPV2RegistrationPortType registrationPortType = wsService.getPort(WSRPV2RegistrationPortType.class);
+ V2RegistrationPortType registrationPortType = wsService.getPort(V2RegistrationPortType.class);
registrationURL = (String)((BindingProvider)registrationPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -352,12 +352,12 @@
Class portTypeClass = null;
try
{
- portTypeClass = WSRPV1MarkupPortType.class;
- WSRPV1MarkupPortType markupPortType = wsService.getPort(WSRPV1MarkupPortType.class);
+ portTypeClass = V1MarkupPortType.class;
+ V1MarkupPortType markupPortType = wsService.getPort(V1MarkupPortType.class);
markupURL = (String)((BindingProvider)markupPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
- portTypeClass = WSRPV1ServiceDescriptionPortType.class;
- WSRPV1ServiceDescriptionPortType sdPort = wsService.getPort(WSRPV1ServiceDescriptionPortType.class);
+ portTypeClass = V1ServiceDescriptionPortType.class;
+ V1ServiceDescriptionPortType sdPort = wsService.getPort(V1ServiceDescriptionPortType.class);
serviceDescriptionURL = (String)((BindingProvider)sdPort).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -368,7 +368,7 @@
try
{
- WSRPV1PortletManagementPortType managementPortType = wsService.getPort(WSRPV1PortletManagementPortType.class);
+ V1PortletManagementPortType managementPortType = wsService.getPort(V1PortletManagementPortType.class);
portletManagementURL = (String)((BindingProvider)managementPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -379,7 +379,7 @@
try
{
- WSRPV1RegistrationPortType registrationPortType = wsService.getPort(WSRPV1RegistrationPortType.class);
+ V1RegistrationPortType registrationPortType = wsService.getPort(V1RegistrationPortType.class);
registrationURL = (String)((BindingProvider)registrationPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
}
catch (Exception e)
@@ -415,12 +415,12 @@
{
if (isV2)
{
- WSRPV2ServiceDescriptionPortType port = getService(WSRPV2ServiceDescriptionPortType.class);
+ V2ServiceDescriptionPortType port = getService(V2ServiceDescriptionPortType.class);
return new V2ServiceDescriptionService(port);
}
else
{
- WSRPV1ServiceDescriptionPortType port = getService(WSRPV1ServiceDescriptionPortType.class);
+ V1ServiceDescriptionPortType port = getService(V1ServiceDescriptionPortType.class);
return new V1ServiceDescriptionService(port);
}
}
@@ -429,12 +429,12 @@
{
if (isV2)
{
- WSRPV2MarkupPortType port = getService(WSRPV2MarkupPortType.class);
+ V2MarkupPortType port = getService(V2MarkupPortType.class);
return new V2MarkupService(port);
}
else
{
- WSRPV1MarkupPortType port = getService(WSRPV1MarkupPortType.class);
+ V1MarkupPortType port = getService(V1MarkupPortType.class);
return new V1MarkupService(port);
}
}
@@ -443,12 +443,12 @@
{
if (isV2)
{
- WSRPV2PortletManagementPortType port = getService(WSRPV2PortletManagementPortType.class);
+ V2PortletManagementPortType port = getService(V2PortletManagementPortType.class);
return new V2PortletManagementService(port);
}
else
{
- WSRPV1PortletManagementPortType port = getService(WSRPV1PortletManagementPortType.class);
+ V1PortletManagementPortType port = getService(V1PortletManagementPortType.class);
return new V1PortletManagementService(port);
}
}
@@ -457,12 +457,12 @@
{
if (isV2)
{
- WSRPV2RegistrationPortType port = getService(WSRPV2RegistrationPortType.class);
+ V2RegistrationPortType port = getService(V2RegistrationPortType.class);
return new V2RegistrationService(port);
}
else
{
- WSRPV1RegistrationPortType port = getService(WSRPV1RegistrationPortType.class);
+ V1RegistrationPortType port = getService(V1RegistrationPortType.class);
return new V1RegistrationService(port);
}
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1MarkupService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1MarkupService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1MarkupService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -26,6 +26,7 @@
import org.gatein.wsrp.WSRPExceptionFactory;
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.services.MarkupService;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
import org.gatein.wsrp.spec.v1.V1ToV2Converter;
import org.gatein.wsrp.spec.v1.V2ToV1Converter;
import org.oasis.wsrp.v1.V1AccessDenied;
@@ -46,7 +47,6 @@
import org.oasis.wsrp.v1.V1UnsupportedMode;
import org.oasis.wsrp.v1.V1UnsupportedWindowState;
import org.oasis.wsrp.v1.V1UpdateResponse;
-import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.EventParams;
import org.oasis.wsrp.v2.Extension;
@@ -86,9 +86,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V1MarkupService extends MarkupService<WSRPV1MarkupPortType>
+public class V1MarkupService extends MarkupService<V1MarkupPortType>
{
- public V1MarkupService(WSRPV1MarkupPortType port)
+ public V1MarkupService(V1MarkupPortType port)
{
super(port);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1PortletManagementService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1PortletManagementService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1PortletManagementService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -27,6 +27,7 @@
import org.gatein.wsrp.WSRPExceptionFactory;
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.services.PortletManagementService;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
import org.gatein.wsrp.spec.v1.V1ToV2Converter;
import org.gatein.wsrp.spec.v1.V2ToV1Converter;
import org.oasis.wsrp.v1.V1AccessDenied;
@@ -43,7 +44,6 @@
import org.oasis.wsrp.v1.V1Property;
import org.oasis.wsrp.v1.V1ResetProperty;
import org.oasis.wsrp.v1.V1ResourceList;
-import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.CopiedPortlet;
import org.oasis.wsrp.v2.ExportByValueNotSupported;
@@ -83,9 +83,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V1PortletManagementService extends PortletManagementService<WSRPV1PortletManagementPortType>
+public class V1PortletManagementService extends PortletManagementService<V1PortletManagementPortType>
{
- public V1PortletManagementService(WSRPV1PortletManagementPortType port)
+ public V1PortletManagementService(V1PortletManagementPortType port)
{
super(port);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1RegistrationService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1RegistrationService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1RegistrationService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -26,13 +26,13 @@
import org.gatein.wsrp.WSRPExceptionFactory;
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.services.RegistrationService;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
import org.gatein.wsrp.spec.v1.V1ToV2Converter;
import org.gatein.wsrp.spec.v1.V2ToV1Converter;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1InvalidRegistration;
import org.oasis.wsrp.v1.V1MissingParameters;
import org.oasis.wsrp.v1.V1OperationFailed;
-import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.Extension;
import org.oasis.wsrp.v2.GetRegistrationLifetime;
@@ -56,9 +56,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V1RegistrationService extends RegistrationService<WSRPV1RegistrationPortType>
+public class V1RegistrationService extends RegistrationService<V1RegistrationPortType>
{
- public V1RegistrationService(WSRPV1RegistrationPortType service)
+ public V1RegistrationService(V1RegistrationPortType service)
{
super(service);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1ServiceDescriptionService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1ServiceDescriptionService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/V1ServiceDescriptionService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -25,6 +25,7 @@
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.services.ServiceDescriptionService;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
import org.gatein.wsrp.spec.v1.V1ToV2Converter;
import org.gatein.wsrp.spec.v1.V2ToV1Converter;
import org.oasis.wsrp.v1.V1CookieProtocol;
@@ -36,7 +37,6 @@
import org.oasis.wsrp.v1.V1PortletDescription;
import org.oasis.wsrp.v1.V1RegistrationContext;
import org.oasis.wsrp.v1.V1ResourceList;
-import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
import org.oasis.wsrp.v2.CookieProtocol;
import org.oasis.wsrp.v2.EventDescription;
import org.oasis.wsrp.v2.ExportDescription;
@@ -61,9 +61,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V1ServiceDescriptionService extends ServiceDescriptionService<WSRPV1ServiceDescriptionPortType>
+public class V1ServiceDescriptionService extends ServiceDescriptionService<V1ServiceDescriptionPortType>
{
- public V1ServiceDescriptionService(WSRPV1ServiceDescriptionPortType port)
+ public V1ServiceDescriptionService(V1ServiceDescriptionPortType port)
{
super(port);
}
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1MarkupPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1MarkupPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1MarkupPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,39 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v1.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v1_Markup_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v1:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V1MarkupPortType extends WSRPV1MarkupPortType
+{
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1PortletManagementPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1PortletManagementPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1PortletManagementPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,39 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v1.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v1_PortletManagement_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v1:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V1PortletManagementPortType extends WSRPV1PortletManagementPortType
+{
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1RegistrationPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1RegistrationPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1RegistrationPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,39 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v1.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v1_Registration_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v1:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V1RegistrationPortType extends WSRPV1RegistrationPortType
+{
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1ServiceDescriptionPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1ServiceDescriptionPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v1/interfaces/V1ServiceDescriptionPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,40 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v1.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v1_ServiceDescription_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v1:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V1ServiceDescriptionPortType extends WSRPV1ServiceDescriptionPortType
+{
+
+}
+
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2MarkupService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2MarkupService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2MarkupService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -24,6 +24,7 @@
package org.gatein.wsrp.services.v2;
import org.gatein.wsrp.services.MarkupService;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.EventParams;
import org.oasis.wsrp.v2.Extension;
@@ -55,7 +56,6 @@
import org.oasis.wsrp.v2.UnsupportedWindowState;
import org.oasis.wsrp.v2.UpdateResponse;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
import javax.xml.ws.Holder;
import java.util.List;
@@ -64,9 +64,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V2MarkupService extends MarkupService<WSRPV2MarkupPortType>
+public class V2MarkupService extends MarkupService<V2MarkupPortType>
{
- public V2MarkupService(WSRPV2MarkupPortType port)
+ public V2MarkupService(V2MarkupPortType port)
{
super(port);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2PortletManagementService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2PortletManagementService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2PortletManagementService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,7 @@
package org.gatein.wsrp.services.v2;
import org.gatein.wsrp.services.PortletManagementService;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.CopiedPortlet;
import org.oasis.wsrp.v2.ExportByValueNotSupported;
@@ -54,7 +55,6 @@
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.SetExportLifetime;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
import javax.xml.ws.Holder;
import java.util.List;
@@ -63,9 +63,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V2PortletManagementService extends PortletManagementService<WSRPV2PortletManagementPortType>
+public class V2PortletManagementService extends PortletManagementService<V2PortletManagementPortType>
{
- public V2PortletManagementService(WSRPV2PortletManagementPortType port)
+ public V2PortletManagementService(V2PortletManagementPortType port)
{
super(port);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2RegistrationService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2RegistrationService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2RegistrationService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,7 @@
package org.gatein.wsrp.services.v2;
import org.gatein.wsrp.services.RegistrationService;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.Extension;
import org.oasis.wsrp.v2.GetRegistrationLifetime;
@@ -38,7 +39,6 @@
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.SetRegistrationLifetime;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
import javax.xml.ws.Holder;
import java.util.List;
@@ -47,9 +47,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V2RegistrationService extends RegistrationService<WSRPV2RegistrationPortType>
+public class V2RegistrationService extends RegistrationService<V2RegistrationPortType>
{
- public V2RegistrationService(WSRPV2RegistrationPortType service)
+ public V2RegistrationService(V2RegistrationPortType service)
{
super(service);
}
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2ServiceDescriptionService.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2ServiceDescriptionService.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/V2ServiceDescriptionService.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,7 @@
package org.gatein.wsrp.services.v2;
import org.gatein.wsrp.services.ServiceDescriptionService;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.oasis.wsrp.v2.CookieProtocol;
import org.oasis.wsrp.v2.EventDescription;
import org.oasis.wsrp.v2.ExportDescription;
@@ -39,7 +40,6 @@
import org.oasis.wsrp.v2.ResourceList;
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
import javax.xml.ws.Holder;
import java.util.List;
@@ -48,9 +48,9 @@
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision$
*/
-public class V2ServiceDescriptionService extends ServiceDescriptionService<WSRPV2ServiceDescriptionPortType> implements WSRPV2ServiceDescriptionPortType
+public class V2ServiceDescriptionService extends ServiceDescriptionService<V2ServiceDescriptionPortType> implements V2ServiceDescriptionPortType
{
- public V2ServiceDescriptionService(WSRPV2ServiceDescriptionPortType service)
+ public V2ServiceDescriptionService(V2ServiceDescriptionPortType service)
{
super(service);
}
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2MarkupPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2MarkupPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2MarkupPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,40 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v2.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v2_Markup_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V2MarkupPortType extends WSRPV2MarkupPortType
+{
+
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2PortletManagementPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2PortletManagementPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2PortletManagementPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,40 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v2.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v2_PortletManagement_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V2PortletManagementPortType extends WSRPV2PortletManagementPortType
+{
+
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2RegistrationPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2RegistrationPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2RegistrationPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,40 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v2.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v2_Registration_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V2RegistrationPortType extends WSRPV2RegistrationPortType
+{
+
+}
+
Added: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2ServiceDescriptionPortType.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2ServiceDescriptionPortType.java (rev 0)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/v2/interfaces/V2ServiceDescriptionPortType.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,40 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.gatein.wsrp.services.v2.interfaces;
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+@WebService(name = "WSRP_v2_ServiceDescription_PortType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:intf")
+@HandlerChain(file = "../../consumer-handler-chains.xml")
+public interface V2ServiceDescriptionPortType extends WSRPV2ServiceDescriptionPortType
+{
+
+}
+
Added: components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/services/consumer-handler-chains.xml
===================================================================
--- components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/services/consumer-handler-chains.xml (rev 0)
+++ components/wsrp/trunk/consumer/src/main/resources/org/gatein/wsrp/services/consumer-handler-chains.xml 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns1="http://org.jboss.ws/jaxws/samples/logicalhandler"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee javaee_web_services_1_2.xsd">
+ <handler-chain>
+ <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+ <handler>
+ <handler-name>ConsumerWSSecurityHandler</handler-name>
+ <handler-class>org.wsrp.wss.jboss5.handlers.ConsumerWSSecurityHandler</handler-class>
+ </handler>
+ </handler-chain>
+</handler-chains>
+
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/services/SOAPServiceFactoryTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/services/SOAPServiceFactoryTestCase.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/services/SOAPServiceFactoryTestCase.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -25,6 +25,14 @@
import junit.framework.TestCase;
import org.gatein.wsrp.services.SOAPServiceFactory;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
@@ -44,8 +52,8 @@
public class SOAPServiceFactoryTestCase extends TestCase
{
private SOAPServiceFactory factory;
- public static final Class[] WSRP2_PORT_TYPES = new Class[]{WSRPV2MarkupPortType.class, WSRPV2ServiceDescriptionPortType.class, WSRPV2PortletManagementPortType.class, WSRPV2RegistrationPortType.class};
- public static final Class[] WSRP1_PORT_TYPES = new Class[]{WSRPV1MarkupPortType.class, WSRPV1ServiceDescriptionPortType.class, WSRPV1PortletManagementPortType.class, WSRPV1RegistrationPortType.class};
+ public static final Class[] WSRP2_PORT_TYPES = new Class[]{V2MarkupPortType.class, V2ServiceDescriptionPortType.class, V2PortletManagementPortType.class, V2RegistrationPortType.class};
+ public static final Class[] WSRP1_PORT_TYPES = new Class[]{V1MarkupPortType.class, V1ServiceDescriptionPortType.class, V1PortletManagementPortType.class, V1RegistrationPortType.class};
@Override
protected void setUp() throws Exception
@@ -84,7 +92,7 @@
factory.setWsdlDefinitionURL(getWSDLURL("wsdl/missing-registration-non-std-ns.wsdl"));
// missing-registration-non-std-ns.wsdl doesn't contain registration port
- checkPorts(WSRPV2MarkupPortType.class, WSRPV2ServiceDescriptionPortType.class, WSRPV2PortletManagementPortType.class);
+ checkPorts(V2MarkupPortType.class, V2ServiceDescriptionPortType.class, V2PortletManagementPortType.class);
}
public void testSimpleV2Service() throws Exception
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -36,6 +36,10 @@
import org.gatein.wsrp.services.v1.V1PortletManagementService;
import org.gatein.wsrp.services.v1.V1RegistrationService;
import org.gatein.wsrp.services.v1.V1ServiceDescriptionService;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
import org.gatein.wsrp.test.support.RequestedMarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1GetMarkup;
@@ -156,22 +160,22 @@
public ServiceDescriptionService getServiceDescriptionService() throws Exception
{
- return new V1ServiceDescriptionService(getService(WSRPV1ServiceDescriptionPortType.class));
+ return new V1ServiceDescriptionService(getService(V1ServiceDescriptionPortType.class));
}
public MarkupService getMarkupService() throws Exception
{
- return new V1MarkupService(getService(WSRPV1MarkupPortType.class));
+ return new V1MarkupService(getService(V1MarkupPortType.class));
}
public PortletManagementService getPortletManagementService() throws Exception
{
- return new V1PortletManagementService(getService(WSRPV1PortletManagementPortType.class));
+ return new V1PortletManagementService(getService(V1PortletManagementPortType.class));
}
public RegistrationService getRegistrationService() throws Exception
{
- return new V1RegistrationService(getService(WSRPV1RegistrationPortType.class));
+ return new V1RegistrationService(getService(V1RegistrationPortType.class));
}
public Version getWSRPVersion()
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -27,6 +27,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
import org.gatein.wsrp.WSRPUtils;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
@@ -69,7 +70,7 @@
* @version $Revision: 10337 $
* @since 2.6
*/
-public abstract class MarkupBehavior extends TestProducerBehavior implements WSRPV1MarkupPortType
+public abstract class MarkupBehavior extends TestProducerBehavior implements V1MarkupPortType
{
private List<String> handles = new ArrayList<String>(3);
private BehaviorRegistry registry;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/PortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/PortletManagementBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/PortletManagementBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,7 @@
package org.gatein.wsrp.test.protocol.v1;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1DestroyFailed;
import org.oasis.wsrp.v1.V1Extension;
@@ -53,7 +54,7 @@
* @version $Revision: 8784 $
* @since 2.6
*/
-public class PortletManagementBehavior extends TestProducerBehavior implements WSRPV1PortletManagementPortType
+public class PortletManagementBehavior extends TestProducerBehavior implements V1PortletManagementPortType
{
public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<V1PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<V1ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<List<V1Extension>> extens!
ions) throws V1AccessDenied, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1MissingParameters, V1OperationFailed
{
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/RegistrationBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/RegistrationBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/RegistrationBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,7 @@
package org.gatein.wsrp.test.protocol.v1;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1InvalidRegistration;
import org.oasis.wsrp.v1.V1MissingParameters;
@@ -41,7 +42,7 @@
* @version $Revision: 8784 $
* @since 2.6
*/
-public class RegistrationBehavior extends TestProducerBehavior implements WSRPV1RegistrationPortType
+public class RegistrationBehavior extends TestProducerBehavior implements V1RegistrationPortType
{
public static final String REGISTRATION_HANDLE = "registration";
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/ServiceDescriptionBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/ServiceDescriptionBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/ServiceDescriptionBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -24,6 +24,7 @@
package org.gatein.wsrp.test.protocol.v1;
import org.gatein.wsrp.WSRPConstants;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
import org.oasis.wsrp.v1.V1CookieProtocol;
import org.oasis.wsrp.v1.V1Extension;
@@ -52,7 +53,7 @@
* @version $Revision: 11320 $
* @since 2.6
*/
-public class ServiceDescriptionBehavior extends TestProducerBehavior implements WSRPV1ServiceDescriptionPortType
+public class ServiceDescriptionBehavior extends TestProducerBehavior implements V1ServiceDescriptionPortType
{
protected V1ServiceDescription serviceDescription;
private static final V1ServiceDescription DEFAULT_SERVICE_DESCRIPTION = WSRP1TypeFactory.createServiceDescription(false);
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -23,6 +23,10 @@
package org.gatein.wsrp.test.protocol.v1;
+import org.gatein.wsrp.services.v1.interfaces.V1MarkupPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1PortletManagementPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1RegistrationPortType;
+import org.gatein.wsrp.services.v1.interfaces.V1ServiceDescriptionPortType;
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1CookieProtocol;
@@ -76,7 +80,7 @@
* @version $Revision: 12020 $
* @since 2.4
*/
-public class TestWSRPProducerImpl implements TestWSRPProducer, WSRPV1MarkupPortType, WSRPV1PortletManagementPortType, WSRPV1RegistrationPortType, WSRPV1ServiceDescriptionPortType
+public class TestWSRPProducerImpl implements TestWSRPProducer, V1MarkupPortType, V1PortletManagementPortType, V1RegistrationPortType, V1ServiceDescriptionPortType
{
private int sessionExpirationTime = 600;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -36,6 +36,10 @@
import org.gatein.wsrp.services.v2.V2PortletManagementService;
import org.gatein.wsrp.services.v2.V2RegistrationService;
import org.gatein.wsrp.services.v2.V2ServiceDescriptionService;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.gatein.wsrp.test.support.RequestedMarkupBehavior;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.GetMarkup;
@@ -51,10 +55,6 @@
import org.oasis.wsrp.v2.UnsupportedMimeType;
import org.oasis.wsrp.v2.UnsupportedMode;
import org.oasis.wsrp.v2.UnsupportedWindowState;
-import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
-import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
-import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
-import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
@@ -89,11 +89,11 @@
start();
}
- if (WSRPV2ServiceDescriptionPortType.class.isAssignableFrom(serviceClass))
+ if (V2ServiceDescriptionPortType.class.isAssignableFrom(serviceClass))
{
return (T)registry.getServiceDescriptionBehavior();
}
- if (WSRPV2MarkupPortType.class.isAssignableFrom(serviceClass))
+ if (V2MarkupPortType.class.isAssignableFrom(serviceClass))
{
String requestedMarkupBehavior = RequestedMarkupBehavior.getRequestedMarkupBehavior();
if (requestedMarkupBehavior == null)
@@ -102,11 +102,11 @@
}
return (T)registry.getMarkupBehaviorFor(requestedMarkupBehavior);
}
- if (WSRPV2PortletManagementPortType.class.isAssignableFrom(serviceClass))
+ if (V2PortletManagementPortType.class.isAssignableFrom(serviceClass))
{
return (T)registry.getPortletManagementBehavior();
}
- if (WSRPV2RegistrationPortType.class.isAssignableFrom(serviceClass))
+ if (V2RegistrationPortType.class.isAssignableFrom(serviceClass))
{
return (T)registry.getRegistrationBehavior();
}
@@ -115,22 +115,22 @@
public ServiceDescriptionService getServiceDescriptionService() throws Exception
{
- return new V2ServiceDescriptionService(getService(WSRPV2ServiceDescriptionPortType.class));
+ return new V2ServiceDescriptionService(getService(V2ServiceDescriptionPortType.class));
}
public MarkupService getMarkupService() throws Exception
{
- return new V2MarkupService(getService(WSRPV2MarkupPortType.class));
+ return new V2MarkupService(getService(V2MarkupPortType.class));
}
public PortletManagementService getPortletManagementService() throws Exception
{
- return new V2PortletManagementService(getService(WSRPV2PortletManagementPortType.class));
+ return new V2PortletManagementService(getService(V2PortletManagementPortType.class));
}
public RegistrationService getRegistrationService() throws Exception
{
- return new V2RegistrationService(getService(WSRPV2RegistrationPortType.class));
+ return new V2RegistrationService(getService(V2RegistrationPortType.class));
}
public Version getWSRPVersion()
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -29,6 +29,7 @@
import org.gatein.pc.api.WindowState;
import org.gatein.wsrp.WSRPTypeFactory;
import org.gatein.wsrp.WSRPUtils;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.EventParams;
import org.oasis.wsrp.v2.Extension;
@@ -64,7 +65,6 @@
import org.oasis.wsrp.v2.UnsupportedWindowState;
import org.oasis.wsrp.v2.UpdateResponse;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
@@ -78,7 +78,7 @@
* @version $Revision: 10337 $
* @since 2.6
*/
-public abstract class MarkupBehavior extends TestProducerBehavior implements WSRPV2MarkupPortType
+public abstract class MarkupBehavior extends TestProducerBehavior implements V2MarkupPortType
{
private List<String> handles = new ArrayList<String>(3);
private BehaviorRegistry registry;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -24,6 +24,7 @@
package org.gatein.wsrp.test.protocol.v2;
import org.gatein.common.NotYetImplemented;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.CopiedPortlet;
import org.oasis.wsrp.v2.ExportByValueNotSupported;
@@ -67,7 +68,7 @@
* @version $Revision: 8784 $
* @since 2.6
*/
-public class PortletManagementBehavior extends TestProducerBehavior implements WSRPV2PortletManagementPortType
+public class PortletManagementBehavior extends TestProducerBehavior implements V2PortletManagementPortType
{
public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> modelDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) thro!
ws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -24,6 +24,7 @@
package org.gatein.wsrp.test.protocol.v2;
import org.gatein.common.NotYetImplemented;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.Extension;
import org.oasis.wsrp.v2.GetRegistrationLifetime;
@@ -50,7 +51,7 @@
* @version $Revision: 8784 $
* @since 2.6
*/
-public class RegistrationBehavior extends TestProducerBehavior implements WSRPV2RegistrationPortType
+public class RegistrationBehavior extends TestProducerBehavior implements V2RegistrationPortType
{
public static final String REGISTRATION_HANDLE = "registration";
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -25,6 +25,7 @@
import org.gatein.wsrp.WSRPConstants;
import org.gatein.wsrp.WSRPTypeFactory;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.oasis.wsrp.v2.CookieProtocol;
import org.oasis.wsrp.v2.EventDescription;
import org.oasis.wsrp.v2.ExportDescription;
@@ -43,7 +44,6 @@
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.ServiceDescription;
import org.oasis.wsrp.v2.UserContext;
-import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
@@ -59,7 +59,7 @@
* @version $Revision: 11320 $
* @since 2.6
*/
-public class ServiceDescriptionBehavior extends TestProducerBehavior implements WSRPV2ServiceDescriptionPortType
+public class ServiceDescriptionBehavior extends TestProducerBehavior implements V2ServiceDescriptionPortType
{
protected ServiceDescription serviceDescription;
private static final ServiceDescription DEFAULT_SERVICE_DESCRIPTION = WSRPTypeFactory.createServiceDescription(false);
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -24,6 +24,10 @@
package org.gatein.wsrp.test.protocol.v2;
import org.gatein.common.NotYetImplemented;
+import org.gatein.wsrp.services.v2.interfaces.V2MarkupPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2PortletManagementPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2RegistrationPortType;
+import org.gatein.wsrp.services.v2.interfaces.V2ServiceDescriptionPortType;
import org.gatein.wsrp.spec.v2.WSRP2ExceptionFactory;
import org.oasis.wsrp.v2.AccessDenied;
import org.oasis.wsrp.v2.CookieProtocol;
@@ -100,7 +104,7 @@
* @version $Revision: 12020 $
* @since 2.4
*/
-public class TestWSRPProducerImpl implements TestWSRPProducer, WSRPV2MarkupPortType, WSRPV2PortletManagementPortType, WSRPV2RegistrationPortType, WSRPV2ServiceDescriptionPortType
+public class TestWSRPProducerImpl implements TestWSRPProducer, V2MarkupPortType, V2PortletManagementPortType, V2RegistrationPortType, V2ServiceDescriptionPortType
{
private int sessionExpirationTime = 600;
Modified: components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/RequestProcessor.java
===================================================================
--- components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/RequestProcessor.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/handlers/processors/RequestProcessor.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -45,6 +45,7 @@
import org.gatein.wsrp.WSRPConstants;
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.producer.Utils;
+import org.gatein.wsrp.servlet.ServletAccess;
import org.gatein.wsrp.spec.v2.WSRP2ExceptionFactory;
import org.oasis.wsrp.v2.InvalidHandle;
import org.oasis.wsrp.v2.InvalidRegistration;
@@ -74,6 +75,8 @@
import java.util.Map;
import java.util.Set;
+import javax.servlet.http.HttpServletRequest;
+
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision: 13121 $
@@ -513,40 +516,95 @@
private SecurityContext createSecurityContext(final MimeRequest params, final RuntimeContext runtimeContext,
final org.oasis.wsrp.v2.UserContext wsrpUserContext)
{
+
+ final HttpServletRequest request = ServletAccess.getRequest();
+ final boolean useSecurity;
+ if (request != null && request.getRemoteUser() != null)
+ {
+ useSecurity = true;
+ }
+ else
+ {
+ useSecurity = false;
+ }
+
return new SecurityContext()
{
public boolean isSecure()
{
- return params.isSecureClientCommunication();
+ if (useSecurity)
+ {
+ return request.isSecure();
+ }
+ else
+ {
+ return params.isSecureClientCommunication();
+ }
}
public String getAuthType()
{
- return runtimeContext.getUserAuthentication();
+ if (useSecurity)
+ {
+ return request.getAuthType();
+ }
+ else
+ {
+ return runtimeContext.getUserAuthentication();
+ }
}
public String getRemoteUser()
{
- if (wsrpUserContext != null)
+ if (useSecurity)
{
- return wsrpUserContext.getUserContextKey();
+ return request.getRemoteUser();
}
- return null;
+ else
+ {
+ if (wsrpUserContext != null)
+ {
+ return wsrpUserContext.getUserContextKey();
+ }
+ return null;
+ }
}
public Principal getUserPrincipal()
{
- return null;
+ if (useSecurity)
+ {
+ return request.getUserPrincipal();
+ }
+ else
+ {
+ return null;
+ }
}
public boolean isUserInRole(String roleName)
{
- return wsrpUserContext != null && wsrpUserContext.getUserCategories().contains(roleName);
+ if (useSecurity)
+ {
+ return request.isUserInRole(roleName);
+ }
+ else
+ {
+ return wsrpUserContext != null && wsrpUserContext.getUserCategories().contains(roleName);
+ }
}
public boolean isAuthenticated()
{
- return wsrpUserContext != null;
+ if (useSecurity)
+ {
+ //TODO: is this correct?
+ return request.getUserPrincipal() != null;
+ }
+ else
+ {
+ return wsrpUserContext != null;
+ }
}
};
}
Modified: components/wsrp/trunk/test/src/main/java/org/gatein/wsrp/test/support/MockHttpServletRequest.java
===================================================================
--- components/wsrp/trunk/test/src/main/java/org/gatein/wsrp/test/support/MockHttpServletRequest.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/test/src/main/java/org/gatein/wsrp/test/support/MockHttpServletRequest.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -187,6 +187,10 @@
{
return null;
}
+ if ("getRemoteUser".equals(methodName))
+ {
+ return null;
+ }
throw new UnsupportedOperationException("MockHttpServletRequest does not support: " + method);
}
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/MarkupEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/MarkupEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/MarkupEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -79,6 +79,7 @@
import org.oasis.wsrp.v2.UnsupportedMode;
import org.oasis.wsrp.v2.UnsupportedWindowState;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -96,6 +97,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp_services.wsdl",
endpointInterface = "org.oasis.wsrp.v1.WSRPV1MarkupPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class MarkupEndpoint extends WSRPBaseEndpoint implements WSRPV1MarkupPortType
{
public void performBlockingInteraction(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/PortletManagementEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/PortletManagementEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/PortletManagementEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -71,6 +71,7 @@
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.SetPortletProperties;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -88,6 +89,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp_services.wsdl",
endpointInterface = "org.oasis.wsrp.v1.WSRPV1PortletManagementPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class PortletManagementEndpoint extends WSRPBaseEndpoint implements WSRPV1PortletManagementPortType
{
public void getPortletPropertyDescription(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/RegistrationEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/RegistrationEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/RegistrationEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -48,6 +48,7 @@
import org.oasis.wsrp.v2.RegistrationState;
import org.oasis.wsrp.v2.ResourceSuspended;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -65,6 +66,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp_services.wsdl",
endpointInterface = "org.oasis.wsrp.v1.WSRPV1RegistrationPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class RegistrationEndpoint extends WSRPBaseEndpoint implements WSRPV1RegistrationPortType
{
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/ServiceDescriptionEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/ServiceDescriptionEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v1/ServiceDescriptionEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -46,6 +46,7 @@
import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.ServiceDescription;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -62,6 +63,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp_services.wsdl",
endpointInterface = "org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class ServiceDescriptionEndpoint extends WSRPBaseEndpoint implements WSRPV1ServiceDescriptionPortType
{
public void getServiceDescription(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -68,6 +68,7 @@
import org.oasis.wsrp.v2.UserContext;
import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -86,6 +87,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp-2.0-services.wsdl",
endpointInterface = "org.oasis.wsrp.v2.WSRPV2MarkupPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class MarkupEndpoint extends WSRPBaseEndpoint implements WSRPV2MarkupPortType
{
public void handleEvents(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -72,6 +72,7 @@
import org.oasis.wsrp.v2.UserContext;
import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.ArrayList;
@@ -90,6 +91,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp-2.0-services.wsdl",
endpointInterface = "org.oasis.wsrp.v2.WSRPV2PortletManagementPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class PortletManagementEndpoint extends WSRPBaseEndpoint implements WSRPV2PortletManagementPortType
{
public void getPortletPropertyDescription(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -44,6 +44,7 @@
import org.oasis.wsrp.v2.UserContext;
import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -61,6 +62,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp-2.0-services.wsdl",
endpointInterface = "org.oasis.wsrp.v2.WSRPV2RegistrationPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class RegistrationEndpoint extends WSRPBaseEndpoint implements WSRPV2RegistrationPortType
{
public void register(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java 2011-02-07 22:29:41 UTC (rev 5856)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java 2011-02-07 22:37:15 UTC (rev 5857)
@@ -45,6 +45,7 @@
import org.oasis.wsrp.v2.UserContext;
import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+import javax.jws.HandlerChain;
import javax.jws.WebParam;
import javax.xml.ws.Holder;
import java.util.List;
@@ -61,6 +62,7 @@
wsdlLocation = "/WEB-INF/wsdl/wsrp-2.0-services.wsdl",
endpointInterface = "org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType"
)
+@HandlerChain(file="../producer-handler-chains.xml")
public class ServiceDescriptionEndpoint extends WSRPBaseEndpoint implements WSRPV2ServiceDescriptionPortType
{
public void getServiceDescription(
Added: components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/endpoints/producer-handler-chains.xml
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/endpoints/producer-handler-chains.xml (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/resources/org/gatein/wsrp/endpoints/producer-handler-chains.xml 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns1="http://org.jboss.ws/jaxws/samples/logicalhandler"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee javaee_web_services_1_2.xsd">
+ <handler-chain>
+ <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+ <handler>
+ <handler-name>ProducerWSSecurityHandler</handler-name>
+ <handler-class>org.wsrp.wss.jboss5.handlers.ProducerWSSecurityHandler</handler-class>
+ </handler>
+ </handler-chain>
+</handler-chains>
+
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/jboss-web.xml (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/jboss-web.xml 2011-02-07 22:37:15 UTC (rev 5857)
@@ -0,0 +1,26 @@
+<?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.
+ -->
+<jboss-web>
+ <security-domain>java:/jaas/gatein-domain</security-domain>
+</jboss-web>
13 years, 10 months
gatein SVN: r5856 - in components/wsrp/trunk: ws-security and 9 other directories.
by do-not-reply@jboss.org
Author: mwringe
Date: 2011-02-07 17:29:41 -0500 (Mon, 07 Feb 2011)
New Revision: 5856
Added:
components/wsrp/trunk/ws-security/
components/wsrp/trunk/ws-security/jboss5/
components/wsrp/trunk/ws-security/jboss5/pom.xml
components/wsrp/trunk/ws-security/jboss5/src/
components/wsrp/trunk/ws-security/jboss5/src/main/
components/wsrp/trunk/ws-security/jboss5/src/main/java/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ConsumerWSSecurityHandler.java
components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ProducerWSSecurityHandler.java
Log:
GTNWSRP-123: initial support for wss. Is enough to get the seam example working.
Added: components/wsrp/trunk/ws-security/jboss5/pom.xml
===================================================================
--- components/wsrp/trunk/ws-security/jboss5/pom.xml (rev 0)
+++ components/wsrp/trunk/ws-security/jboss5/pom.xml 2011-02-07 22:29:41 UTC (rev 5856)
@@ -0,0 +1,126 @@
+<!--
+ ~ 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.
+ -->
+
+<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.gatein.wsrp</groupId>
+ <artifactId>wsrp-parent</artifactId>
+ <version>2.1.0-Alpha01-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>wsrp-wss-jboss5</artifactId>
+ <packaging>jar</packaging>
+ <name>GateIn WSRP WS Security for JBoss 5</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.gatein.wsrp</groupId>
+ <artifactId>wsrp-common</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.wsrp</groupId>
+ <artifactId>wsrp-integration-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.wsrp</groupId>
+ <artifactId>wsrp-wsrp2-ws</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.gatein.common</groupId>
+ <artifactId>common-common</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.pc</groupId>
+ <artifactId>pc-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.pc</groupId>
+ <artifactId>pc-portlet</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.gatein.pc</groupId>
+ <artifactId>pc-federation</artifactId>
+ </dependency>
+
+<!-- <dependency>
+ <groupId>org.jboss.ws</groupId>
+ <artifactId>jbossws-spi</artifactId>
+ <version>1.1.2.GA</version>
+ </dependency>-->
+ <dependency>
+ <groupId>org.jboss.ws.native</groupId>
+ <artifactId>jbossws-native-core</artifactId>
+ <version>3.1.2.GA</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.security</groupId>
+ <artifactId>jbosssx-client</artifactId>
+ <version>2.0.3.SP1</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>jboss.web</groupId>
+ <artifactId>jbossweb</artifactId>
+ <version>2.1.3.GA</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbossas</groupId>
+ <artifactId>jboss-as-tomcat</artifactId>
+ <version>5.1.0.GA</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+
+ <!-- Ignore all classes in the org.gatein.wsrp.test packages as they are not tests -->
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <exclude>org/gatein/wsrp/test/**</exclude>
+ </excludes>
+ <!--<parallel>classes</parallel>
+ <threadCount>2</threadCount>-->
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ <version>2.2</version>
+ <executions>
+ <execution>
+ <goals>
+ <goal>test-jar</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ConsumerWSSecurityHandler.java
===================================================================
--- components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ConsumerWSSecurityHandler.java (rev 0)
+++ components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ConsumerWSSecurityHandler.java 2011-02-07 22:29:41 UTC (rev 5856)
@@ -0,0 +1,166 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.wsrp.wss.jboss5.handlers;
+
+import java.security.Principal;
+import java.security.cert.X509Certificate;
+import java.util.Set;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpSession;
+import javax.xml.namespace.QName;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.gatein.wci.security.Credentials;
+import org.gatein.wsrp.servlet.ServletAccess;
+import org.jboss.aspects.security.SecurityClientInterceptor;
+import org.jboss.security.SecurityAssociation;
+import org.jboss.security.SecurityContextAssociation;
+import org.jboss.security.SecurityContextUtil;
+import org.jboss.security.client.SecurityClient;
+import org.jboss.security.client.SecurityClientFactory;
+import org.jboss.web.tomcat.security.SecurityAssociationValve;
+import org.jboss.ws.extensions.security.Util;
+import org.jboss.ws.extensions.security.element.SecurityHeader;
+import org.jboss.ws.extensions.security.element.UsernameToken;
+import org.jboss.ws.extensions.security.element.X509Token;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.w3c.dom.Element;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class ConsumerWSSecurityHandler implements SOAPHandler<SOAPMessageContext>
+{
+ private static Logger log = LoggerFactory.getLogger(ConsumerWSSecurityHandler.class);
+
+ public void close(MessageContext arg0)
+ {
+ //Nothing to do for now
+ }
+
+ public boolean handleFault(SOAPMessageContext soapMessageContext)
+ {
+ return true;
+ }
+
+ public boolean handleMessage(SOAPMessageContext soapMessageContext)
+ {
+ // outbound message means request
+ if (Boolean.TRUE.equals(soapMessageContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY)))
+ {
+ return handleRequest(soapMessageContext);
+ }
+ else
+ {
+ return handleResponse(soapMessageContext);
+ }
+ }
+
+ private boolean handleRequest(SOAPMessageContext soapMessageContext)
+ {
+ try
+ {
+
+ log.debug("Attempting to convert security context to WS-Security header");
+
+ Principal principal = SecurityAssociation.getPrincipal();
+ Object credential = SecurityAssociation.getCredential();
+
+ SOAPMessageContext smc = (SOAPMessageContext) soapMessageContext;
+ SOAPMessage message = smc.getMessage();
+ SecurityHeader header = new SecurityHeader(message.getSOAPHeader().getOwnerDocument());
+
+ if (principal == null)
+ {
+
+ log.debug("No principal to put in WS-Security header");
+ return true;
+
+ }
+ else if (credential instanceof X509Certificate[])
+ {
+
+ log.debug("Adding X509Token to WSRP WS-Security header");
+ header.addToken(new X509Token(((X509Certificate[]) credential)[0], message.getSOAPHeader()
+ .getOwnerDocument()));
+ Element soapHeader = Util.findOrCreateSoapHeader(message.getSOAPHeader().getOwnerDocument()
+ .getDocumentElement());
+
+ Element wsse = header.getElement();
+ wsse.setAttributeNS(soapHeader.getNamespaceURI(), soapHeader.getPrefix() + ":mustUnderstand", "1");
+ soapHeader.insertBefore(wsse, soapHeader.getFirstChild());
+
+ }
+ else if (credential instanceof String)
+ {
+
+ log.debug("Adding UsernameToken to WSRP WS-Security header");
+
+ boolean digest = false;
+ String nonce = null;
+ String created = null;
+
+ header.addToken(new UsernameToken(principal.getName(), (String) credential, message.getSOAPHeader()
+ .getOwnerDocument(), digest, nonce, created));
+ Element soapHeader = Util.findOrCreateSoapHeader(message.getSOAPHeader().getOwnerDocument()
+ .getDocumentElement());
+
+ Element wsse = header.getElement();
+ wsse.setAttributeNS(soapHeader.getNamespaceURI(), soapHeader.getPrefix() + ":mustUnderstand", "1");
+ soapHeader.insertBefore(wsse, soapHeader.getFirstChild());
+
+ }
+ else
+ {
+
+ log.warn("Principal exists, but can not propogate in WS-Security header");
+
+ }
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ //throw new JAXRPCException(e);
+ }
+
+ return true;
+ }
+
+ private boolean handleResponse(SOAPMessageContext soapMessageContext)
+ {
+ return false;
+ }
+
+ public Set<QName> getHeaders()
+ {
+ return null;
+ }
+
+}
+
Added: components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ProducerWSSecurityHandler.java
===================================================================
--- components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ProducerWSSecurityHandler.java (rev 0)
+++ components/wsrp/trunk/ws-security/jboss5/src/main/java/org/wsrp/wss/jboss5/handlers/ProducerWSSecurityHandler.java 2011-02-07 22:29:41 UTC (rev 5856)
@@ -0,0 +1,183 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2011, 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.wsrp.wss.jboss5.handlers;
+
+import java.security.Principal;
+import java.security.cert.X509Certificate;
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.xml.namespace.QName;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.apache.catalina.connector.Request;
+import org.gatein.wsrp.servlet.ServletAccess;
+import org.jboss.web.tomcat.security.SecurityAssociationValve;
+import org.jboss.ws.extensions.security.Constants;
+import org.jboss.ws.extensions.security.Util;
+import org.jboss.ws.extensions.security.element.BinarySecurityToken;
+import org.jboss.ws.extensions.security.element.UsernameToken;
+import org.jboss.ws.extensions.security.element.X509Token;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.w3c.dom.Element;
+
+/**
+ * @author <a href="mailto:mwringe@redhat.com">Matt Wringe</a>
+ * @version $Revision$
+ */
+public class ProducerWSSecurityHandler implements SOAPHandler<SOAPMessageContext>
+{
+ private static Logger log = LoggerFactory.getLogger(ProducerWSSecurityHandler.class);
+
+ public Set<QName> getHeaders()
+ {
+ Set<QName> qNames = new HashSet<QName>();
+ qNames.add(Constants.WSSE_HEADER_QNAME);
+ return qNames;
+ }
+
+ public void close(MessageContext arg0)
+ {
+ //Nothing to do for now
+ }
+
+ public boolean handleFault(SOAPMessageContext arg0)
+ {
+ return false;
+ }
+
+ public boolean handleMessage(SOAPMessageContext soapMessageContext)
+ {
+ // outbound message means request
+ if (Boolean.TRUE.equals(soapMessageContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY)))
+ {
+ return handleRequest(soapMessageContext);
+ }
+ else
+ {
+ return handleResponse(soapMessageContext);
+ }
+ }
+
+ private boolean handleResponse(SOAPMessageContext soapMessageContext)
+ {
+ try
+ {
+ log.debug("Attempting to extract WS-Security header and create user context");
+ //final Request r = (Request)ServletAccess.getRequest();
+ final Request r = (Request) (SecurityAssociationValve.activeRequest.get());
+
+ SOAPMessageContext smc = (SOAPMessageContext) soapMessageContext;
+ SOAPMessage message = smc.getMessage();
+
+ Element headerElement = Util.findElement(message.getSOAPHeader().getOwnerDocument().getDocumentElement(),
+ "Security", Constants.WSSE_NS);
+
+ if (headerElement != null)
+ {
+ Element child = Util.getFirstChildElement(headerElement);
+ String tag = child.getLocalName();
+
+ if (tag.equals("BinarySecurityToken"))
+ {
+
+ log.debug("Attempting to authenticate with a BinarySecurityToken");
+ BinarySecurityToken token = BinarySecurityToken.createBinarySecurityToken(child);
+ if (token instanceof X509Token)
+ {
+ X509Certificate cert = ((X509Token) token).getCert();
+ Principal principal = r.getContext().getRealm().authenticate(new X509Certificate[]
+ {cert});
+ if (principal != null)
+ {
+ r.setAuthType(tag);
+ r.setUserPrincipal(principal);
+ }
+ else
+ {
+ throw new Exception("Could not authenticate principal from BinarySecurityToken");
+ }
+ }
+ else
+ {
+ //throw new UnsupportedSecurityTokenException(tag + ": Only an X509 BinarySecurityToken is suppported.");
+ System.out.println(tag + ": Only an X509 BinarySecurityToken is suppported.");
+ }
+
+ }
+ else if (tag.equals("UsernameToken"))
+ {
+
+ log.debug("Attempting to authenticate with a UsernameToken");
+ UsernameToken token = new UsernameToken(child);
+ Principal principal = r.getContext().getRealm().authenticate(token.getUsername(), token.getPassword());
+ if (principal != null)
+ {
+ r.setAuthType(tag);
+ r.setUserPrincipal(principal);
+ }
+ else
+ {
+ throw new Exception("Could not authenticate from UsernameToken");
+ }
+
+ }
+ else
+ {
+
+ //throw new UnsupportedSecurityTokenException(tag + ": Only BinarySecurityToken or UsernameToken is suppported.");
+ System.out.println(tag + ": Only BinarySecurityToken or UsernameToken is suppported.");
+
+ }
+
+ if (Util.getNextSiblingElement(headerElement) != null)
+ {
+ //throw new UnsupportedSecurityTokenException(tag + ": Only a single X509 BinarySecurityToken or UsernameToken is suppported.");
+ System.out.println(tag + ": Only a single X509 BinarySecurityToken or UsernameToken is suppported.");
+ }
+
+ //Remove the header since it's been processed
+ headerElement.getParentNode().removeChild(headerElement);
+ }
+ }
+ catch (Exception e)
+ {
+ //throw new JAXRPCException(e);
+ e.printStackTrace();
+ }
+
+ return true;
+ }
+
+ private boolean handleRequest(SOAPMessageContext soapMessageContext)
+ {
+ //The Producer should only handle setting the header for now
+ return false;
+ }
+
+}
13 years, 10 months
gatein SVN: r5855 - in portal/branches/shindig2: gadgets/server/src/main/webapp/containers/default and 1 other directory.
by do-not-reply@jboss.org
Author: alain_defrance
Date: 2011-02-07 10:55:09 -0500 (Mon, 07 Feb 2011)
New Revision: 5855
Modified:
portal/branches/shindig2/component/application-registry/src/main/java/org/exoplatform/application/gadget/impl/GadgetRegistryServiceImpl.java
portal/branches/shindig2/gadgets/server/src/main/webapp/containers/default/container.js
Log:
Fix gadgets display
Modified: portal/branches/shindig2/component/application-registry/src/main/java/org/exoplatform/application/gadget/impl/GadgetRegistryServiceImpl.java
===================================================================
--- portal/branches/shindig2/component/application-registry/src/main/java/org/exoplatform/application/gadget/impl/GadgetRegistryServiceImpl.java 2011-02-07 14:18:32 UTC (rev 5854)
+++ portal/branches/shindig2/component/application-registry/src/main/java/org/exoplatform/application/gadget/impl/GadgetRegistryServiceImpl.java 2011-02-07 15:55:09 UTC (rev 5855)
@@ -332,11 +332,6 @@
}
return done;
}
- catch (Exception e)
- {
- e.printStackTrace();
- return null;
- }
finally
{
chromatticLifeCycle.closeContext(true);
Modified: portal/branches/shindig2/gadgets/server/src/main/webapp/containers/default/container.js
===================================================================
--- portal/branches/shindig2/gadgets/server/src/main/webapp/containers/default/container.js 2011-02-07 14:18:32 UTC (rev 5854)
+++ portal/branches/shindig2/gadgets/server/src/main/webapp/containers/default/container.js 2011-02-07 15:55:09 UTC (rev 5855)
@@ -45,7 +45,8 @@
// Container must be an array; this allows multiple containers
// to share configuration.
// TODO: Move out accel container config into a separate accel.js file.
-{"gadgets.container" : ["default", "accel"],
+// TODO : remove "" container
+{"gadgets.container" : ["default", "accel", ""],
// Set of regular expressions to validate the parent parameter. This is
// necessary to support situations where you want a single container to support
@@ -114,12 +115,12 @@
"gadgets.uri.js.path" : "/eXoGadgetServer/gadgets/js",
// Default concat Uri config; used for testing.
-"gadgets.uri.concat.host" : "http://localhost:8080/",
+"gadgets.uri.concat.host" : "localhost:8080",
"gadgets.uri.concat.path" : "/eXoGadgetServer/gadgets/concat",
"gadgets.uri.concat.js.splitToken" : "false",
// Default proxy Uri config; used for testing.
-"gadgets.uri.proxy.host" : "http://localhost:8080/",
+"gadgets.uri.proxy.host" : "localhost:8080",
"gadgets.uri.proxy.path" : "/eXoGadgetServer/gadgets/proxy",
// This config data will be passed down to javascript. Please
13 years, 10 months