[jbossws-commits] JBossWS SVN: r4239 - in container: jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40 and 7 other directories.
jbossws-commits at lists.jboss.org
jbossws-commits at lists.jboss.org
Tue Aug 7 15:13:42 EDT 2007
Author: heiko.braun at jboss.com
Date: 2007-08-07 15:13:42 -0400 (Tue, 07 Aug 2007)
New Revision: 4239
Added:
container/jboss40/trunk/ant.properties
container/jboss40/trunk/jboss40.iml
container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXRPCDeployerHookJSE2.java
container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXWSDeployerHookJSE2.java
container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/Phase2DeployerHookJSE.java
container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/RuntimeLoaderDeploymentAspect.java
container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE2.java
container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE2.java
container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/Phase2DeployerHookJSE.java
container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/RuntimeLoaderDeploymentAspect.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE2.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE2.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/Phase2DeployerHookJSE.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/RuntimeLoaderDeploymentAspect.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/WebServiceDeployerJSE2.java
Modified:
container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/AbstractDeployerHook.java
container/jboss40/trunk/src/main/resources/jbossws-jboss40-config.xml
container/jboss40/trunk/version.properties
container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java
container/jboss42/trunk/src/main/resources/jbossws-jboss42-config.xml
container/jboss42/trunk/version.properties
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/EJBArchiveMetaDataAdapterEJB3.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java
container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java
container/jboss50/trunk/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml
container/jboss50/trunk/version.properties
Log:
1.0.0.CR1: Support 2 phase JSE deployments. Cleanup classloading
Added: container/jboss40/trunk/ant.properties
===================================================================
--- container/jboss40/trunk/ant.properties (rev 0)
+++ container/jboss40/trunk/ant.properties 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,26 @@
+#
+# A sample ant properties file
+#
+# $Id: ant.properties.example 3995 2007-07-26 08:52:45Z thomas.diesler at jboss.com $
+
+# JBoss Home
+jboss40.home=/home/hbraun/dev/prj/jbossas/tags/JBoss_4_0_5_GA_CP05/build/output/jboss-4.0.5.GA_CP05-ejb3
+
+# The JBoss settings
+jboss.server.instance=default
+
+# JBoss Repository
+jboss.repository=file:/home/hbraun/dev/prj/jboss.local.repository/
+#jboss.repository=http://repository.jboss.org
+
+# JBossWS Release
+jboss.local.repository=/home/hbraun/dev/prj/jboss.local.repository/
+
+# Force thirdparty HTTP get
+#force.thirdparty.get=true
+
+# Java Compiler options
+javac.debug=yes
+javac.deprecation=no
+javac.fail.onerror=yes
+javac.verbose=no
Added: container/jboss40/trunk/jboss40.iml
===================================================================
--- container/jboss40/trunk/jboss40.iml (rev 0)
+++ container/jboss40/trunk/jboss40.iml 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module version="4" relativePaths="true" type="JAVA_MODULE">
+ <component name="ModuleRootManager" />
+ <component name="NewModuleRootManager" inherit-compiler-output="true">
+ <exclude-output />
+ <content url="file://$MODULE_DIR$">
+ <sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
+ </content>
+ <orderEntry type="inheritedJdk" />
+ <orderEntry type="sourceFolder" forTests="false" />
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/saaj-api.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/jbossws-spi.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/dom4j.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/jaxrpc-api.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/jbossws-common.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/jaxws-api.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/thirdparty/jsr181-api.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../jbossas/tags/JBoss_4_0_5_GA_CP05/build/output/jboss-4.0.5.GA_CP05-ejb3/lib/jboss-xml-binding.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../jbossas/tags/JBoss_4_0_5_GA_CP05/build/output/jboss-4.0.5.GA_CP05-ejb3/lib/jboss-system.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../jbossas/tags/JBoss_4_0_5_GA_CP05/build/output/jboss-4.0.5.GA_CP05-ejb3/lib/jboss-common.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../jbossas/tags/JBoss_4_0_5_GA_CP05/build/output/jboss-4.0.5.GA_CP05-ejb3/server/default/lib/jboss.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntryProperties />
+ </component>
+</module>
+
Modified: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/AbstractDeployerHook.java
===================================================================
--- container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/AbstractDeployerHook.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/AbstractDeployerHook.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -53,12 +53,20 @@
private List<ObjectName> phaseOneInterceptors;
private List<ObjectName> phaseTwoInterceptors;
+ protected String deploymentManagerName;
+
+ /** MC provided property **/
+ public void setDeploymentManagerName(String deploymentManagerName)
+ {
+ this.deploymentManagerName = deploymentManagerName;
+ }
+
public DeploymentAspectManager getDeploymentAspectManager()
{
if(null == deploymentAspectManager)
{
SPIProvider spiProvider = SPIProviderResolver.getInstance().getProvider();
- deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager(getDeploymentType());
+ deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager( deploymentManagerName );
}
return deploymentAspectManager;
Added: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXRPCDeployerHookJSE2.java
===================================================================
--- container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXRPCDeployerHookJSE2.java (rev 0)
+++ container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXRPCDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss40;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+import org.jboss.deployment.DeploymentInfo;
+
+/**
+ * A deployer JAXRPC JSE Endpoints
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 25-Apr-2007
+ */
+public class JAXRPCDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXRPC_JSE;
+ }
+
+
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit, "WEB-INF/webservices.xml");
+ return (wsMetaData!=null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXRPCDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXWSDeployerHookJSE2.java
===================================================================
--- container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXWSDeployerHookJSE2.java (rev 0)
+++ container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXWSDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss40;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+import org.jboss.deployment.DeploymentInfo;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class JAXWSDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXWS_JSE;
+ }
+
+
+ /**
+ * Reject JAX-RPC deployments
+ */
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit, "WEB-INF/webservices.xml"); // JAX-RPC artifact
+ return (wsMetaData==null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/JAXWSDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/Phase2DeployerHookJSE.java
===================================================================
--- container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/Phase2DeployerHookJSE.java (rev 0)
+++ container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/Phase2DeployerHookJSE.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss40;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.deployment.DeploymentInfo;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public abstract class Phase2DeployerHookJSE extends AbstractDeployerHookJSE
+{
+ /**
+ * The deployment should be created in phase 1.
+ */
+ /**
+ * Create an endpoint for every servlet-link in webservices.xml
+ */
+ @Override
+ public Deployment createDeployment(DeploymentInfo di)
+ {
+ Deployment deployment = (Deployment)di.context.get(Deployment.class);
+ if(null == deployment)
+ throw new IllegalArgumentException("spi.Deployment missing. Should be created in Phase 1");
+
+ return deployment;
+ }
+
+ /**
+ * A phase 2 deployer hook needs to reject first-place
+ * JSE deployments and wait for those that are re-written.
+ * We rely on the fact that spi.Deployment is created in phase 1.
+ */
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo di)
+ {
+ if(super.isWebServiceDeployment(di) == false)
+ return false;
+
+ Deployment deployment = (Deployment)di.context.get(Deployment.class);
+ return deployment!=null;
+ }
+
+}
Property changes on: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/Phase2DeployerHookJSE.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/RuntimeLoaderDeploymentAspect.java
===================================================================
--- container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/RuntimeLoaderDeploymentAspect.java (rev 0)
+++ container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/RuntimeLoaderDeploymentAspect.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss40;
+
+import org.jboss.wsf.spi.deployment.DeploymentAspect;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.ApplicationMetaData;
+
+/**
+ * Determines the correct runtime loader for per deployment type
+ * and makes it available through the {@link org.jboss.wsf.spi.deployment.Deployment}.
+ *
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class RuntimeLoaderDeploymentAspect extends DeploymentAspect
+{
+
+ public void create(Deployment dep)
+ {
+
+ // JSE endpoints
+ if (dep.getAttachment(WebMetaData.class) != null)
+ {
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
+ ClassLoader classLoader = webMetaData.getContextLoader();
+ dep.setRuntimeClassLoader(classLoader);
+ }
+
+ // EJB3 endpoints
+ else if (dep.getType() == Deployment.DeploymentType.JAXRPC_EJB3
+ || dep.getType() == Deployment.DeploymentType.JAXWS_EJB3 )
+ {
+ // loader provided by the deployer hook
+ if(null == dep.getRuntimeClassLoader())
+ throw new IllegalArgumentException("Runtime loader not provided");
+ }
+
+ // EJB21 endpoints
+ else if(dep.getAttachment(ApplicationMetaData.class)!=null)
+ {
+ // loader provided by the deployer hook
+ if(null == dep.getRuntimeClassLoader())
+ throw new IllegalArgumentException("Runtime loader not provided");
+ }
+
+ else
+ {
+ throw new IllegalArgumentException("Unable to determine runtime loader");
+ }
+ }
+}
Property changes on: container/jboss40/trunk/src/main/java/org/jboss/wsf/container/jboss40/RuntimeLoaderDeploymentAspect.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: container/jboss40/trunk/src/main/resources/jbossws-jboss40-config.xml
===================================================================
--- container/jboss40/trunk/src/main/resources/jbossws-jboss40-config.xml 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss40/trunk/src/main/resources/jbossws-jboss40-config.xml 2007-08-07 19:13:42 UTC (rev 4239)
@@ -47,28 +47,54 @@
<!--
Register DeployerHooks with JBoss deployers
-->
+ <!-- Phase 1-->
<bean name="WSDeployerHook_JAXRPC_JSE" class="org.jboss.wsf.container.jboss40.JAXRPCDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<property name="phaseOneInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorJSE</value>
</list>
</property>
</bean>
+ <!-- Phase 2 -->
+ <bean name="WSDeployerHook_JAXRPC_JSE2" class="org.jboss.wsf.container.jboss40.JAXRPCDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+
<bean name="WSDeployerHook_JAXRPC_EJB21" class="org.jboss.wsf.container.jboss40.JAXRPCDeployerHookEJB21">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<property name="phaseTwoInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorEJB21</value>
</list>
</property>
</bean>
+
<bean name="WSDeployerHook_JAXWS_JSE" class="org.jboss.wsf.container.jboss40.JAXWSDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<property name="phaseOneInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorJSE</value>
</list>
</property>
</bean>
+ <!-- Phase 2 -->
+ <bean name="WSDeployerHook_JAXWS_JSE2" class="org.jboss.wsf.container.jboss40.JAXWSDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+
<bean name="WSDeployerHook_JAXWS_EJB3" class="org.jboss.wsf.container.jboss40.JAXWSDeployerHookEJB3">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<property name="phaseTwoInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorEJB3</value>
@@ -82,6 +108,9 @@
<bean name="WSDeploymentAspectManagerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerJSE</property>
</bean>
+ <bean name="WSDeploymentAspectManagerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
+ <property name="name">WSDeploymentAspectManagerJSE2</property>
+ </bean>
<bean name="WSDeploymentAspectManagerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerEJB</property>
</bean>
@@ -155,6 +184,11 @@
<property name="securityHandlerEJB21"><inject bean="WSSecurityHandlerEJB21"/></property>
<property name="securityHandlerEJB3"><inject bean="WSSecurityHandlerEJB3"/></property>
</bean>
+
+ <bean name="WSRuntimeLoaderDeploymentAspect" class="org.jboss.wsf.container.jboss40.RuntimeLoaderDeploymentAspect">
+ <property name="requires">ContainerMetaData</property>
+ <property name="provides">RuntimeLoader</property>
+ </bean>
<!-- Deployment aspect helper beans -->
<bean name="WSApplicationMetaDataAdapterEJB21" class="org.jboss.wsf.container.jboss40.EJBArchiveMetaDataAdapterEJB21"/>
@@ -175,29 +209,46 @@
</bean>
<!-- Deployment aspect installers -->
+
+ <!-- Phase 1 -->
<bean name="WSDeploymentAspectInstallerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
<inject bean="WSContainerMetaDataDeploymentAspect"/>
+ <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
+ <inject bean="WSURLPatternDeploymentAspect"/>
+ <inject bean="WSEndpointHandlerDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+
+ <!-- Phase 2 -->
+ <bean name="WSDeploymentAspectInstallerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
+ <property name="parent"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE2"/></property>
+ <property name="sortAspectsOnCreate">false</property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
- <inject bean="WSEndpointHandlerDeploymentAspect"/>
<inject bean="WSEndpointLifecycleDeploymentAspect"/>
<inject bean="WSEndpointMetricsDeploymentAspect"/>
<inject bean="WSEndpointNameDeploymentAspect"/>
<inject bean="WSEndpointRegistryDeploymentAspect"/>
- <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
- <inject bean="WSURLPatternDeploymentAspect"/>
</set>
</property>
+ <depends>WSDeploymentAspectInstallerJSE</depends>
</bean>
+
<bean name="WSDeploymentAspectInstallerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSContainerMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
@@ -217,6 +268,7 @@
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSEndpointAPIDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
<inject bean="WSEndpointHandlerDeploymentAspect"/>
Modified: container/jboss40/trunk/version.properties
===================================================================
--- container/jboss40/trunk/version.properties 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss40/trunk/version.properties 2007-08-07 19:13:42 UTC (rev 4239)
@@ -5,8 +5,8 @@
specification.vendor=JBoss (http://www.jboss.org)
specification.version=jbossws-2.0
-version.id=snapshot
-repository.id=snapshot
+version.id=2.0.1.CR2
+repository.id=2.0.1.CR2
implementation.title=JBoss Web Services - Integration JBoss40
implementation.url=http://www.jboss.org/products/jbossws
@@ -20,4 +20,4 @@
dom4j=1.6.1
sun-jaxrpc=1.1
-sun-jaxws=2.1.1
\ No newline at end of file
+sun-jaxws=2.1.1
Modified: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java
===================================================================
--- container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -53,12 +53,20 @@
private List<ObjectName> phaseOneInterceptors;
private List<ObjectName> phaseTwoInterceptors;
+ protected String deploymentManagerName;
+
+ /** MC provided property **/
+ public void setDeploymentManagerName(String deploymentManagerName)
+ {
+ this.deploymentManagerName = deploymentManagerName;
+ }
+
public DeploymentAspectManager getDeploymentAspectManager()
{
if(null == deploymentAspectManager)
{
SPIProvider spiProvider = SPIProviderResolver.getInstance().getProvider();
- deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager(getDeploymentType());
+ deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager( deploymentManagerName );
}
return deploymentAspectManager;
Added: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE2.java
===================================================================
--- container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE2.java (rev 0)
+++ container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss42;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+import org.jboss.deployment.DeploymentInfo;
+
+/**
+ * A deployer JAXRPC JSE Endpoints
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 25-Apr-2007
+ */
+public class JAXRPCDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXRPC_JSE;
+ }
+
+
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit, "WEB-INF/webservices.xml");
+ return (wsMetaData!=null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE2.java
===================================================================
--- container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE2.java (rev 0)
+++ container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,59 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss42;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+import org.jboss.deployment.DeploymentInfo;
+import org.jboss.metadata.WebMetaData;
+
+import javax.jws.WebService;
+import javax.xml.ws.WebServiceProvider;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.Map;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class JAXWSDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXWS_JSE;
+ }
+
+
+ /**
+ * Reject JAX-RPC deployments
+ */
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit, "WEB-INF/webservices.xml"); // JAX-RPC artifact
+ return (wsMetaData==null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/Phase2DeployerHookJSE.java
===================================================================
--- container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/Phase2DeployerHookJSE.java (rev 0)
+++ container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/Phase2DeployerHookJSE.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss42;
+
+import org.jboss.deployment.DeploymentInfo;
+import org.jboss.wsf.spi.deployment.Deployment;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public abstract class Phase2DeployerHookJSE extends AbstractDeployerHookJSE
+{
+ /**
+ * The deployment should be created in phase 1.
+ */
+ /**
+ * Create an endpoint for every servlet-link in webservices.xml
+ */
+ @Override
+ public Deployment createDeployment(DeploymentInfo di)
+ {
+ Deployment deployment = (Deployment)di.context.get(Deployment.class);
+ if(null == deployment)
+ throw new IllegalArgumentException("spi.Deployment missing. Should be created in Phase 1");
+
+ return deployment;
+ }
+
+ /**
+ * A phase 2 deployer hook needs to reject first-place
+ * JSE deployments and wait for those that are re-written.
+ * We rely on the fact that spi.Deployment is created in phase 1.
+ */
+ @Override
+ public boolean isWebServiceDeployment(DeploymentInfo di)
+ {
+ if(super.isWebServiceDeployment(di) == false)
+ return false;
+
+ Deployment deployment = (Deployment)di.context.get(Deployment.class);
+ return deployment!=null;
+ }
+
+}
Property changes on: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/Phase2DeployerHookJSE.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/RuntimeLoaderDeploymentAspect.java
===================================================================
--- container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/RuntimeLoaderDeploymentAspect.java (rev 0)
+++ container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/RuntimeLoaderDeploymentAspect.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss42;
+
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.ApplicationMetaData;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.DeploymentAspect;
+
+/**
+ * Determines the correct runtime loader for per deployment type
+ * and makes it available through the {@link org.jboss.wsf.spi.deployment.Deployment}.
+ *
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class RuntimeLoaderDeploymentAspect extends DeploymentAspect
+{
+
+ public void create(Deployment dep)
+ {
+
+ // JSE endpoints
+ if (dep.getAttachment(WebMetaData.class) != null)
+ {
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
+ ClassLoader classLoader = webMetaData.getContextLoader();
+ dep.setRuntimeClassLoader(classLoader);
+ }
+
+ // EJB3 endpoints
+ else if (dep.getType() == Deployment.DeploymentType.JAXRPC_EJB3
+ || dep.getType() == Deployment.DeploymentType.JAXWS_EJB3 )
+ {
+ // loader provided by the deployer hook
+ if(null == dep.getRuntimeClassLoader())
+ throw new IllegalArgumentException("Runtime loader not provided");
+ }
+
+ // EJB21 endpoints
+ else if(dep.getAttachment(ApplicationMetaData.class)!=null)
+ {
+ // loader provided by the deployer hook
+ if(null == dep.getRuntimeClassLoader())
+ throw new IllegalArgumentException("Runtime loader not provided");
+ }
+
+ else
+ {
+ throw new IllegalArgumentException("Unable to determine runtime loader");
+ }
+ }
+}
Property changes on: container/jboss42/trunk/src/main/java/org/jboss/wsf/container/jboss42/RuntimeLoaderDeploymentAspect.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: container/jboss42/trunk/src/main/resources/jbossws-jboss42-config.xml
===================================================================
--- container/jboss42/trunk/src/main/resources/jbossws-jboss42-config.xml 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss42/trunk/src/main/resources/jbossws-jboss42-config.xml 2007-08-07 19:13:42 UTC (rev 4239)
@@ -55,28 +55,58 @@
<!--
Register DeployerHooks with JBoss deployers
-->
+
+ <!-- Phase 1 -->
<bean name="WSDeployerHook_JAXRPC_JSE" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<property name="phaseOneInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorJSE</value>
</list>
</property>
</bean>
+
+ <!-- Phase 2 -->
+ <bean name="WSDeployerHook_JAXRPC_JSE2" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+
<bean name="WSDeployerHook_JAXRPC_EJB21" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookEJB21">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<property name="phaseTwoInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorEJB21</value>
</list>
</property>
</bean>
+
+ <!-- Phase 1 -->
<bean name="WSDeployerHook_JAXWS_JSE" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<property name="phaseOneInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorJSE</value>
</list>
</property>
</bean>
+
+ <!-- Phase 2 -->
+ <bean name="WSDeployerHook_JAXWS_JSE2" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+
<bean name="WSDeployerHook_JAXWS_EJB3" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookEJB3">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<property name="phaseTwoInterceptors">
<list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
<value>jboss.ws:service=DeployerInterceptorEJB3</value>
@@ -90,6 +120,9 @@
<bean name="WSDeploymentAspectManagerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerJSE</property>
</bean>
+ <bean name="WSDeploymentAspectManagerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
+ <property name="name">WSDeploymentAspectManagerJSE2</property>
+ </bean>
<bean name="WSDeploymentAspectManagerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerEJB</property>
</bean>
@@ -143,7 +176,8 @@
</bean>
<bean name="WSModifyWebMetaDataDeploymentAspect" class="org.jboss.wsf.container.jboss42.ModifyWebMetaDataDeploymentAspect">
- <property name="requires">ContextProperties, ContainerMetaData, StackDescriptor</property>
+ <!--property name="requires">ContextProperties, ContainerMetaData, StackDescriptor</property-->
+ <property name="requires">ContextProperties, ContainerMetaData</property>
<property name="webXMLRewriter"><inject bean="WSWebXMLRewriter"/></property>
</bean>
@@ -163,6 +197,11 @@
<property name="securityHandlerEJB21"><inject bean="WSSecurityHandlerEJB21"/></property>
<property name="securityHandlerEJB3"><inject bean="WSSecurityHandlerEJB3"/></property>
</bean>
+
+ <bean name="WSRuntimeLoaderDeploymentAspect" class="org.jboss.wsf.container.jboss42.RuntimeLoaderDeploymentAspect">
+ <property name="requires">ContainerMetaData</property>
+ <property name="provides">RuntimeLoader</property>
+ </bean>
<!-- Deployment aspect helper beans -->
<bean name="WSApplicationMetaDataAdapterEJB21" class="org.jboss.wsf.container.jboss42.EJBArchiveMetaDataAdapterEJB21"/>
@@ -181,30 +220,46 @@
<property name="desciptorModifier"><inject bean="WSWebAppDesciptorModifier"/></property>
</bean>
- <!-- Deployment aspect installers -->
+ <!-- Deployment aspect installers -->
+ <!-- Phase 1 -->
<bean name="WSDeploymentAspectInstallerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
<inject bean="WSContainerMetaDataDeploymentAspect"/>
+ <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
+ <inject bean="WSURLPatternDeploymentAspect"/>
+ <inject bean="WSEndpointHandlerDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+
+ <!-- Phase 2 -->
+ <bean name="WSDeploymentAspectInstallerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
+ <property name="parent"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE2"/></property>
+ <property name="sortAspectsOnCreate">false</property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
- <inject bean="WSEndpointHandlerDeploymentAspect"/>
<inject bean="WSEndpointLifecycleDeploymentAspect"/>
<inject bean="WSEndpointMetricsDeploymentAspect"/>
<inject bean="WSEndpointNameDeploymentAspect"/>
<inject bean="WSEndpointRegistryDeploymentAspect"/>
- <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
- <inject bean="WSURLPatternDeploymentAspect"/>
</set>
</property>
+ <depends>WSDeploymentAspectInstallerJSE</depends>
</bean>
+
<bean name="WSDeploymentAspectInstallerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSContainerMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
@@ -224,6 +279,7 @@
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSEndpointAPIDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
<inject bean="WSEndpointHandlerDeploymentAspect"/>
Modified: container/jboss42/trunk/version.properties
===================================================================
--- container/jboss42/trunk/version.properties 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss42/trunk/version.properties 2007-08-07 19:13:42 UTC (rev 4239)
@@ -5,8 +5,8 @@
specification.vendor=JBoss (http://www.jboss.org)
specification.version=jbossws-2.0
-version.id=snapshot
-repository.id=snapshot
+version.id=2.0.1.CR2
+repository.id=2.0.1.CR2
implementation.title=JBoss Web Services - Integration JBoss42
implementation.url=http://www.jboss.org/products/jbossws
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -46,12 +46,20 @@
private DeploymentAspectManager deploymentAspectManager;
private DeploymentModelFactory deploymentModelFactory;
+ protected String deploymentManagerName;
+
+ /** MC provided property **/
+ public void setDeploymentManagerName(String deploymentManagerName)
+ {
+ this.deploymentManagerName = deploymentManagerName;
+ }
+
public DeploymentAspectManager getDeploymentAspectManager()
{
if(null == deploymentAspectManager)
{
SPIProvider spiProvider = SPIProviderResolver.getInstance().getProvider();
- deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager(getDeploymentType());
+ deploymentAspectManager = spiProvider.getSPI(DeploymentAspectManagerFactory.class).getDeploymentAspectManager( deploymentManagerName );
}
return deploymentAspectManager;
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/EJBArchiveMetaDataAdapterEJB3.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/EJBArchiveMetaDataAdapterEJB3.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/EJBArchiveMetaDataAdapterEJB3.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -64,7 +64,7 @@
dep.addAttachment(Ejb3Deployment.class, ejb3Deployment);
EjbJarDD jarDD = unit.getAttachment(EjbJarDD.class);
- EJBArchiveMetaData umd = new EJBArchiveMetaData();
+ EJBArchiveMetaData umd = new EJBArchiveMetaData();
buildUnifiedBeanMetaData(umd, ejb3Deployment);
buildWebservicesMetaData(umd, jarDD);
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -44,7 +44,7 @@
*/
public class JAXRPCDeployerHookEJB21 extends AbstractDeployerHookEJB
{
- /** Get the deployemnt type this deployer can handle
+ /** Get the deployemnt type this deployer can handle
*/
public DeploymentType getDeploymentType()
{
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -44,7 +44,7 @@
*/
public class JAXRPCDeployerHookJSE extends AbstractDeployerHookJSE
{
- /** Get the deployemnt type this deployer can handle
+ /** Get the deployemnt type this deployer can handle
*/
public DeploymentType getDeploymentType()
{
@@ -59,7 +59,7 @@
{
ArchiveDeployment dep = newDeployment(unit);
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setRuntimeClassLoader(null);
+ dep.setRuntimeClassLoader(null); // TODO: Create RuntimeLoader aspect
dep.setType(getDeploymentType());
Service service = dep.getService();
Added: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE2.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE2.java (rev 0)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,52 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50;
+
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.web.Servlet;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+
+/**
+ * A deployer JAXRPC JSE Endpoints
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 25-Apr-2007
+ */
+public class JAXRPCDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXRPC_JSE;
+ }
+
+
+ @Override
+ public boolean isWebServiceDeployment(DeploymentUnit unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);
+ return (wsMetaData!=null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -46,7 +46,7 @@
*/
public class JAXWSDeployerHookEJB3 extends AbstractDeployerHookEJB
{
- /** Get the deployemnt type this deployer can handle
+ /** Get the deployemnt type this deployer can handle
*/
public DeploymentType getDeploymentType()
{
Modified: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -46,7 +46,7 @@
*/
public class JAXWSDeployerHookJSE extends AbstractDeployerHookJSE
{
- /** Get the deployemnt type this deployer can handle
+ /** Get the deployment type this deployer can handle
*/
public DeploymentType getDeploymentType()
{
@@ -57,8 +57,7 @@
public Deployment createDeployment(DeploymentUnit unit)
{
ArchiveDeployment dep = newDeployment(unit);
- dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setRuntimeClassLoader(null);
+ dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
dep.setType(getDeploymentType());
Service service = dep.getService();
Added: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE2.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE2.java (rev 0)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,59 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50;
+
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.NameValuePair;
+import org.jboss.metadata.web.Servlet;
+
+import java.util.Iterator;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class JAXWSDeployerHookJSE2 extends Phase2DeployerHookJSE
+{
+ /** Get the deployment type this deployer can handle
+ */
+ public Deployment.DeploymentType getDeploymentType()
+ {
+ return Deployment.DeploymentType.JAXWS_JSE;
+ }
+
+
+ /**
+ * Reject JAX-RPC deployments.
+ *
+ * @param unit
+ * @return
+ */
+ public boolean isWebServiceDeployment(DeploymentUnit unit)
+ {
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);// JAX-RPC artefact
+ return (wsMetaData==null && super.isWebServiceDeployment(unit));
+ }
+}
Property changes on: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/Phase2DeployerHookJSE.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/Phase2DeployerHookJSE.java (rev 0)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/Phase2DeployerHookJSE.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,107 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50;
+
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.NameValuePair;
+import org.jboss.metadata.web.Servlet;
+
+import java.util.Iterator;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public abstract class Phase2DeployerHookJSE extends AbstractDeployerHookJSE
+{
+ /**
+ * The deployment should be created in phase 1.
+ */
+ public Deployment createDeployment(DeploymentUnit unit)
+ {
+ Deployment dep = unit.getAttachment(Deployment.class);
+ if(null == dep)
+ throw new IllegalStateException("spi.Deployment missing. It should be created in Phase 1");
+
+ return dep;
+ }
+
+ /**
+ * A phase 2 deployer hook needs to reject first-place
+ * JSE deployments and wait for those that are re-written.
+ * We do it by inspecting the Servlet init parameter.
+ * @param unit
+ * @return
+ */
+ @Override
+ public boolean isWebServiceDeployment(DeploymentUnit unit)
+ {
+ if(super.isWebServiceDeployment(unit) == false)
+ return false;
+
+ Deployment deployment = unit.getAttachment(Deployment.class);
+ boolean isModified =false;
+ if(deployment!=null)
+ isModified = isModifiedServletClass(deployment);
+ return isModified;
+ }
+
+ private boolean isModifiedServletClass(Deployment dep)
+ {
+ boolean modified = false;
+
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
+ if (webMetaData != null)
+ {
+ for (Servlet servlet : webMetaData.getServlets())
+ {
+ String orgServletClass = servlet.getServletClass();
+
+ // JSP
+ if (orgServletClass == null || orgServletClass.length() == 0)
+ {
+ log.debug("Innore servlet class: " + orgServletClass);
+ continue;
+ }
+
+ modified = isAlreadyModified(servlet);
+ }
+ }
+
+ return modified;
+ }
+
+ private boolean isAlreadyModified(Servlet servlet)
+ {
+ Iterator itParams = servlet.getInitParams().iterator();
+ while (itParams.hasNext())
+ {
+ NameValuePair pair = (NameValuePair)itParams.next();
+ if (Endpoint.SEPID_DOMAIN_ENDPOINT.equals(pair.getName()))
+ return true;
+ }
+ return false;
+ }
+}
Property changes on: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/Phase2DeployerHookJSE.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/RuntimeLoaderDeploymentAspect.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/RuntimeLoaderDeploymentAspect.java (rev 0)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/RuntimeLoaderDeploymentAspect.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,68 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50;
+
+import org.jboss.metadata.ApplicationMetaData;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.DeploymentAspect;
+import org.jboss.ejb3.Ejb3Deployment;
+
+/**
+ * Determines the correct runtime loader for per deployment type
+ * and makes it available through the {@link Deployment}.
+ *
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class RuntimeLoaderDeploymentAspect extends DeploymentAspect
+{
+
+ public void create(Deployment dep)
+ {
+
+ // JSE endpoints
+ if (dep.getAttachment(WebMetaData.class) != null)
+ {
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
+ ClassLoader classLoader = webMetaData.getContextLoader();
+ dep.setRuntimeClassLoader(classLoader);
+ }
+
+ // EJB3 endpoints
+ else if (dep.getAttachment(Ejb3Deployment.class) != null)
+ {
+ dep.setRuntimeClassLoader(dep.getInitialClassLoader());
+ }
+
+ // EJB21 endpoints
+ else if (dep.getAttachment(ApplicationMetaData.class) != null)
+ {
+ dep.setRuntimeClassLoader(dep.getInitialClassLoader());
+ }
+
+ else
+ {
+ throw new IllegalArgumentException("Unable to determine runtime loader");
+ }
+ }
+}
Property changes on: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/RuntimeLoaderDeploymentAspect.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/WebServiceDeployerJSE2.java
===================================================================
--- container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/WebServiceDeployerJSE2.java (rev 0)
+++ container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/WebServiceDeployerJSE2.java 2007-08-07 19:13:42 UTC (rev 4239)
@@ -0,0 +1,43 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50;
+
+/**
+ * @author Heiko.Braun at jboss.com
+ * @version $Revision$
+ */
+public class WebServiceDeployerJSE2 extends AbstractWebServiceDeployer
+{
+ private int relOrderPhase1;
+
+
+ public void setRelOrderPhase1(int relOrderPhase1)
+ {
+ this.relOrderPhase1 = relOrderPhase1;
+ }
+
+ @Override
+ public int getRelativeOrder()
+ {
+ return relOrderPhase1 + 1;
+ }
+}
\ No newline at end of file
Property changes on: container/jboss50/trunk/src/main/java/org/jboss/wsf/container/jboss50/WebServiceDeployerJSE2.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: container/jboss50/trunk/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml
===================================================================
--- container/jboss50/trunk/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml 2007-08-07 19:13:42 UTC (rev 4239)
@@ -74,11 +74,23 @@
<property name="relOrderWar"><inject bean="WarDeployer" property="relativeOrder"/></property>
<depends>WebAppParsingDeployer</depends>
</bean>
+
+ <!--
+ Phase 2 of JSE web service deployments.
+ This deployer depends on the RuntimeClassloader being available.
+ -->
+ <bean name="WebServiceDeployerJSE2" class="org.jboss.wsf.container.jboss50.WebServiceDeployerJSE2">
+ <property name="relOrderPhase1"><inject bean="WebServiceDeployerJSE" property="relativeOrder"/></property>
+ <depends>WebServiceDeployerJSE</depends>
+ </bean>
- <!--
+ <!--
Register DeployerHooks with JBoss deployers
-->
+
+ <!-- Phase 1 of JSE JAX-RPC -->
<bean name="WSDeployerHook_JAXRPC_JSE" class="org.jboss.wsf.container.jboss50.JAXRPCDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<install bean="WebServiceDeployerJSE" method="addDeployerHook">
<parameter>
<this/>
@@ -91,7 +103,24 @@
</uninstall>
<depends>WebServiceDeployerJSE</depends>
</bean>
+ <!-- Phase 2 of JSE JAX-RPC -->
+ <bean name="WSDeployerHook_JAXRPC_JSE2" class="org.jboss.wsf.container.jboss50.JAXRPCDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <install bean="WebServiceDeployerJSE2" method="addDeployerHook">
+ <parameter>
+ <this/>
+ </parameter>
+ </install>
+ <uninstall bean="WebServiceDeployerJSE2" method="removeDeployerHook">
+ <parameter>
+ <this/>
+ </parameter>
+ </uninstall>
+ <depends>WebServiceDeployerJSE2</depends>
+ </bean>
+
<bean name="WSDeployerHook_JAXRPC_EJB21" class="org.jboss.wsf.container.jboss50.JAXRPCDeployerHookEJB21">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<install bean="WebServiceDeployerEJB" method="addDeployerHook">
<parameter>
<this/>
@@ -104,7 +133,10 @@
</uninstall>
<depends>WebServiceDeployerEJB</depends>
</bean>
+
+ <!-- Phase 1 of JSE JAX-WS-->
<bean name="WSDeployerHook_JAXWS_JSE" class="org.jboss.wsf.container.jboss50.JAXWSDeployerHookJSE">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE</property>
<install bean="WebServiceDeployerJSE" method="addDeployerHook">
<parameter>
<this/>
@@ -117,7 +149,24 @@
</uninstall>
<depends>WebServiceDeployerJSE</depends>
</bean>
+ <!-- Phase 2 of JSE JAX-WS -->
+ <bean name="WSDeployerHook_JAXWS_JSE2" class="org.jboss.wsf.container.jboss50.JAXWSDeployerHookJSE2">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerJSE2</property>
+ <install bean="WebServiceDeployerJSE2" method="addDeployerHook">
+ <parameter>
+ <this/>
+ </parameter>
+ </install>
+ <uninstall bean="WebServiceDeployerJSE2" method="removeDeployerHook">
+ <parameter>
+ <this/>
+ </parameter>
+ </uninstall>
+ <depends>WebServiceDeployerJSE2</depends>
+ </bean>
+
<bean name="WSDeployerHook_JAXWS_EJB3" class="org.jboss.wsf.container.jboss50.JAXWSDeployerHookEJB3">
+ <property name="deploymentManagerName">WSDeploymentAspectManagerEJB</property>
<install bean="WebServiceDeployerEJB" method="addDeployerHook">
<parameter>
<this/>
@@ -137,6 +186,9 @@
<bean name="WSDeploymentAspectManagerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerJSE</property>
</bean>
+ <bean name="WSDeploymentAspectManagerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
+ <property name="name">WSDeploymentAspectManagerJSE2</property>
+ </bean>
<bean name="WSDeploymentAspectManagerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
<property name="name">WSDeploymentAspectManagerEJB</property>
</bean>
@@ -189,7 +241,8 @@
</bean>
<bean name="WSModifyWebMetaDataDeploymentAspect" class="org.jboss.wsf.container.jboss50.ModifyWebMetaDataDeploymentAspect">
- <property name="requires">ContextProperties, StackDescriptor</property>
+ <property name="requires">ContextProperties</property>
+ <!--property name="requires">ContextProperties, StackDescriptor</property-->
</bean>
<bean name="WSURLPatternDeploymentAspect" class="org.jboss.wsf.framework.deployment.BackwardCompatibleURLPatternDeploymentAspect">
@@ -209,6 +262,11 @@
<property name="securityHandlerEJB21"><inject bean="WSSecurityHandlerEJB21"/></property>
<property name="securityHandlerEJB3"><inject bean="WSSecurityHandlerEJB3"/></property>
</bean>
+
+ <bean name="WSRuntimeLoaderDeploymentAspect" class="org.jboss.wsf.container.jboss50.RuntimeLoaderDeploymentAspect">
+ <!--property name="requires">ContextProperties</property TODO: link both DAM's-->
+ <property name="provides">RuntimeLoader</property>
+ </bean>
<!-- Deployment aspect helper beans -->
<bean name="WSEndpointMetrics" class="org.jboss.wsf.framework.management.EndpointMetricsImpl"/>
@@ -219,12 +277,26 @@
<property name="desciptorModifier"><inject bean="WSWebAppDesciptorModifier"/></property>
</bean>
- <!-- Deployment aspect installers -->
+ <!-- Deployment aspect installers -->
+
+ <!-- Phase 1 -->
<bean name="WSDeploymentAspectInstallerJSE" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+
+ <!-- Phase 2 -->
+ <bean name="WSDeploymentAspectInstallerJSE2" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE2"/></property>
+ <property name="sortAspectsOnCreate">false</property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSContainerMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
@@ -233,16 +305,17 @@
<inject bean="WSEndpointMetricsDeploymentAspect"/>
<inject bean="WSEndpointNameDeploymentAspect"/>
<inject bean="WSEndpointRegistryDeploymentAspect"/>
- <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
<inject bean="WSURLPatternDeploymentAspect"/>
</set>
</property>
</bean>
+
<bean name="WSDeploymentAspectInstallerEJB" class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
<property name="manager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSContainerMetaDataDeploymentAspect"/>
<inject bean="WSContextRootDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
@@ -262,6 +335,7 @@
<property name="sortAspectsOnCreate">false</property>
<property name="aspects">
<set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSRuntimeLoaderDeploymentAspect"/>
<inject bean="WSEndpointAPIDeploymentAspect"/>
<inject bean="WSEndpointAddressDeploymentAspect"/>
<inject bean="WSEndpointHandlerDeploymentAspect"/>
Modified: container/jboss50/trunk/version.properties
===================================================================
--- container/jboss50/trunk/version.properties 2007-08-07 11:11:28 UTC (rev 4238)
+++ container/jboss50/trunk/version.properties 2007-08-07 19:13:42 UTC (rev 4239)
@@ -5,8 +5,8 @@
specification.vendor=JBoss (http://www.jboss.org)
specification.version=jbossws-2.0
-version.id=snapshot
-repository.id=snapshot
+version.id=2.0.1.CR2
+repository.id=2.0.1.CR2
implementation.title=JBoss Web Services - Integration JBoss50
implementation.url=http://www.jboss.org/products/jbossws
More information about the jbossws-commits
mailing list