Author: thomas.diesler(a)jboss.com
Date: 2007-07-26 04:52:45 -0400 (Thu, 26 Jul 2007)
New Revision: 3995
Modified:
trunk/build/ant.properties.example
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractApplicationMetaDataAdapter.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ApplicationMetaDataAdapterEJB3.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/DeploymentInfoAdapter.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookEJB21.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookEJB3.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebMetaDataAdapter.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeployment.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicService.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DeploymentModelFactoryImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/jaxws/impl/JBossWSProviderImpl.java
Log:
Fix ear deployment. Mandatory Deployment.initialLoader
Modified: trunk/build/ant.properties.example
===================================================================
--- trunk/build/ant.properties.example 2007-07-25 19:19:15 UTC (rev 3994)
+++ trunk/build/ant.properties.example 2007-07-26 08:52:45 UTC (rev 3995)
@@ -5,7 +5,7 @@
# Optional JBoss Home
#jboss50.home=/home/tdiesler/svn/jbossas/trunk/build/output/jboss-5.0.0.Beta3
-#jboss42.home=/home/tdiesler/svn/jbossas/tags/JBoss_4_2_0_GA/build/output/jboss-4.2.0.GA
+#jboss42.home=/home/tdiesler/svn/jbossas/tags/JBoss_4_2_1_GA/build/output/jboss-4.2.1.GA
#jboss40.home=/home/tdiesler/svn/jbossas/tags/JBoss_4_0_5_GA/build/output/jboss-4.0.5.GA-ejb3
# The JBoss server under test. This can be [jboss50|jboss42|jboss40]
@@ -36,12 +36,12 @@
hudson.jboss50.build=jboss-5.0.0.Beta3
hudson.jboss50.rev=HEAD
-hudson.jboss42.url=https://svn.jboss.org/repos/jbossas/branches/Branch_4_2
+hudson.jboss42.url=https://svn.jboss.org/repos/jbossas/tags/JBoss_4_2_1_GA
hudson.jboss42.build=jboss-4.2.1.GA
hudson.jboss42.rev=HEAD
-hudson.jboss40.url=https://svn.jboss.org/repos/jbossas/branches/Branch_4_0
-hudson.jboss40.build=jboss-4.0.5.SP1
+hudson.jboss40.url=https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_5_GA
+hudson.jboss40.build=jboss-4.0.5.GA
hudson.jboss40.rev=HEAD
hudson.mail.recipients=
Modified:
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java
===================================================================
---
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -72,7 +72,7 @@
// Build the container independent deployment info
SPIProvider spiProvider = SPIProviderResolver.getInstance().getProvider();
- Deployment dep =
spiProvider.getSPI(DeploymentModelFactory.class).createDeployment();
+ Deployment dep =
spiProvider.getSPI(DeploymentModelFactory.class).createDeployment(di.ucl);
UnifiedDeploymentInfo udi = new
JAXRPCClientDeployment(Deployment.DeploymentType.JAXRPC_CLIENT);
DeploymentInfoAdapter adapter =
DeploymentInfoAdapterFactory.getDeploymentInfoAdapter();
adapter.buildDeploymentInfo(dep, udi, di);
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractApplicationMetaDataAdapter.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractApplicationMetaDataAdapter.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractApplicationMetaDataAdapter.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -49,16 +49,14 @@
ApplicationMetaData apmd = (ApplicationMetaData)di.metaData;
dep.getContext().addAttachment(ApplicationMetaData.class, apmd);
- UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
- buildUnifiedBeanMetaData(umd, apmd);
- umd.setConfigName(apmd.getConfigName());
- umd.setConfigFile(apmd.getConfigFile());
- umd.setWebServiceContextRoot(apmd.getWebServiceContextRoot());
- umd.setSecurityDomain(apmd.getSecurityDomain());
- umd.setPublishLocationAdapter(getPublishLocationAdpater(apmd));
-
- dep.getContext().addAttachment(UnifiedApplicationMetaData.class, umd);
- return umd;
+ UnifiedApplicationMetaData appMetaData = new UnifiedApplicationMetaData();
+ buildUnifiedBeanMetaData(appMetaData, apmd);
+ appMetaData.setConfigName(apmd.getConfigName());
+ appMetaData.setConfigFile(apmd.getConfigFile());
+ appMetaData.setWebServiceContextRoot(apmd.getWebServiceContextRoot());
+ appMetaData.setSecurityDomain(apmd.getSecurityDomain());
+ appMetaData.setPublishLocationAdapter(getPublishLocationAdpater(apmd));
+ return appMetaData;
}
protected PublishLocationAdapter getPublishLocationAdpater(final ApplicationMetaData
apmd)
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractDeployerHook.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -75,11 +75,11 @@
return deploymentModelFactory;
}
- public Deployment createDeployment()
+ public Deployment createDeployment(ClassLoader initialLoader)
{
try
{
- return getDeploymentModelFactory().createDeployment();
+ return getDeploymentModelFactory().createDeployment(initialLoader);
}
catch (Exception ex)
{
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ApplicationMetaDataAdapterEJB3.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ApplicationMetaDataAdapterEJB3.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ApplicationMetaDataAdapterEJB3.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -54,27 +54,32 @@
public UnifiedApplicationMetaData buildUnifiedApplicationMetaData(Deployment dep,
UnifiedDeploymentInfo udi)
{
- ObjectName deployedObject =
(ObjectName)dep.getContext().getProperty("DeployedObject");
- Ejb3ModuleMBean ejb3Module = getEJB3Module(deployedObject);
+ UnifiedApplicationMetaData appMetaData = null;
+
+ ObjectName oname =
(ObjectName)dep.getContext().getProperty("DeployedObject");
+
+ // jboss.j2ee:service=EJB3,module=some-ejb3.jar
+ if (oname != null && oname.getDomain().equals("jboss.j2ee")
&& "EJB3".equals(oname.getKeyProperty("service")))
+ {
+ Ejb3ModuleMBean ejb3Module = getEJB3Module(oname);
- ArrayList<UnifiedBeanMetaData> beans = new
ArrayList<UnifiedBeanMetaData>();
- for (Object container : ejb3Module.getContainers().values())
- {
- if (container instanceof StatelessContainer)
+ ArrayList<UnifiedBeanMetaData> beans = new
ArrayList<UnifiedBeanMetaData>();
+ for (Object container : ejb3Module.getContainers().values())
{
- StatelessContainer slc = (StatelessContainer)container;
- UnifiedBeanMetaData usmd = new UnifiedSessionMetaData();
- usmd.setEjbName(slc.getEjbName());
- usmd.setEjbClass(slc.getBeanClassName());
- beans.add(usmd);
+ if (container instanceof StatelessContainer)
+ {
+ StatelessContainer slc = (StatelessContainer)container;
+ UnifiedBeanMetaData usmd = new UnifiedSessionMetaData();
+ usmd.setEjbName(slc.getEjbName());
+ usmd.setEjbClass(slc.getBeanClassName());
+ beans.add(usmd);
+ }
}
+
+ appMetaData = new UnifiedApplicationMetaData();
+ appMetaData.setEnterpriseBeans(beans);
}
-
- UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
- umd.setEnterpriseBeans(beans);
-
- dep.getContext().addAttachment(UnifiedApplicationMetaData.class, umd);
- return umd;
+ return appMetaData;
}
static Ejb3ModuleMBean getEJB3Module(ObjectName objectName)
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/DeploymentInfoAdapter.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/DeploymentInfoAdapter.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/DeploymentInfoAdapter.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -36,6 +36,8 @@
import org.jboss.wsf.spi.deployment.Deployment;
import org.jboss.wsf.spi.deployment.UnifiedDeploymentInfo;
import org.jboss.wsf.spi.deployment.Deployment.DeploymentType;
+import org.jboss.wsf.spi.metadata.j2ee.UnifiedApplicationMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.UnifiedWebMetaData;
/**
* Build container independent deployment info.
@@ -47,7 +49,7 @@
{
// logging support
private static Logger log = Logger.getLogger(DeploymentInfoAdapter.class);
-
+
private ApplicationMetaDataAdapterEJB3 applicationMetaDataAdapterEJB3;
private AbstractApplicationMetaDataAdapter applicationMetaDataAdapterEJB21;
private WebMetaDataAdapter webMetaDataAdapter;
@@ -80,7 +82,7 @@
udi.setVfRoot(new ResourceLoaderAdapter(di.localCl));
udi.setSimpleName(di.shortName);
udi.setUrl(getDeploymentURL(di));
-
+
if (di.deployedObject != null)
dep.getContext().setProperty("DeployedObject", di.deployedObject);
@@ -115,16 +117,21 @@
{
if (di.metaData instanceof WebMetaData)
{
- webMetaDataAdapter.buildUnifiedWebMetaData(dep, udi, di);
- dep.getContext().setProperty(WebXMLRewriter.WEBAPP_URL, udi.getUrl());
+ UnifiedWebMetaData webMetaData = webMetaDataAdapter.buildUnifiedWebMetaData(dep,
udi, di);
+ if (webMetaData != null)
+ dep.getContext().addAttachment(UnifiedWebMetaData.class, webMetaData);
}
else if (dep.getType() == DeploymentType.JAXRPC_EJB3 || dep.getType() ==
DeploymentType.JAXWS_EJB3)
{
- applicationMetaDataAdapterEJB3.buildUnifiedApplicationMetaData(dep, udi);
+ UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB3.buildUnifiedApplicationMetaData(dep, udi);
+ if (appMetaData != null)
+ dep.getContext().addAttachment(UnifiedApplicationMetaData.class,
appMetaData);
}
else if (di.metaData instanceof ApplicationMetaData)
{
- applicationMetaDataAdapterEJB21.buildUnifiedApplicationMetaData(dep, udi, di);
+ UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB21.buildUnifiedApplicationMetaData(dep, udi, di);
+ if (appMetaData != null)
+ dep.getContext().addAttachment(UnifiedApplicationMetaData.class,
appMetaData);
}
}
}
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookEJB21.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookEJB21.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookEJB21.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -51,21 +51,20 @@
}
@Override
- public Deployment createDeployment(DeploymentInfo unit)
+ public Deployment createDeployment(DeploymentInfo di)
{
- Deployment dep = createDeployment();
- dep.setRootFile(new URLLoaderAdapter(unit.localUrl));
- dep.setInitialClassLoader(unit.annotationsCl);
- dep.setRuntimeClassLoader(unit.ucl);
+ Deployment dep = createDeployment(di.annotationsCl);
+ dep.setRootFile(new URLLoaderAdapter(di.localUrl));
+ dep.setRuntimeClassLoader(di.ucl);
dep.setType(getDeploymentType());
Service service = dep.getService();
- ApplicationMetaData appmd = (ApplicationMetaData)unit.metaData;
+ ApplicationMetaData appmd = (ApplicationMetaData)di.metaData;
if (appmd == null)
throw new IllegalStateException("Deployment unit does not contain
application meta data");
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit, null);
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(di, null);
if (wsMetaData == null)
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -57,21 +57,20 @@
* Create an endpoint for every servlet-link in webservices.xml
*/
@Override
- public Deployment createDeployment(DeploymentInfo unit)
+ public Deployment createDeployment(DeploymentInfo di)
{
- Deployment dep = createDeployment();
- dep.setRootFile(new URLLoaderAdapter(unit.localUrl));
- dep.setInitialClassLoader(unit.annotationsCl);
+ Deployment dep = createDeployment(di.annotationsCl);
+ dep.setRootFile(new URLLoaderAdapter(di.localUrl));
dep.setRuntimeClassLoader(null);
dep.setType(getDeploymentType());
Service service = dep.getService();
- WebMetaData webMetaData = (WebMetaData)unit.metaData;
+ WebMetaData webMetaData = (WebMetaData)di.metaData;
if (webMetaData == null)
throw new IllegalStateException("Deployment unit does not contain web meta
data");
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit,
"WEB-INF/webservices.xml");
+ WebservicesMetaData wsMetaData = getWebservicesMetaData(di,
"WEB-INF/webservices.xml");
if (wsMetaData == null)
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookEJB3.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookEJB3.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookEJB3.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -52,17 +52,16 @@
}
@Override
- public Deployment createDeployment(DeploymentInfo unit)
+ public Deployment createDeployment(DeploymentInfo di)
{
- Deployment dep = createDeployment();
- dep.setRootFile(new URLLoaderAdapter(unit.localUrl));
- dep.setInitialClassLoader(unit.annotationsCl);
- dep.setRuntimeClassLoader(unit.ucl);
+ Deployment dep = createDeployment(di.annotationsCl);
+ dep.setRootFile(new URLLoaderAdapter(di.localUrl));
+ dep.setRuntimeClassLoader(di.ucl);
dep.setType(getDeploymentType());
Service service = dep.getService();
- Ejb3ModuleMBean ejb3Module =
ApplicationMetaDataAdapterEJB3.getEJB3Module(unit.deployedObject);
+ Ejb3ModuleMBean ejb3Module =
ApplicationMetaDataAdapterEJB3.getEJB3Module(di.deployedObject);
for (Object manager : ejb3Module.getContainers().values())
{
if (manager instanceof EJBContainer)
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -58,9 +58,8 @@
@Override
public Deployment createDeployment(DeploymentInfo unit)
{
- Deployment dep = createDeployment();
+ Deployment dep = createDeployment(unit.annotationsCl);
dep.setRootFile(new URLLoaderAdapter(unit.localUrl));
- dep.setInitialClassLoader(unit.annotationsCl);
dep.setRuntimeClassLoader(null);
dep.setType(getDeploymentType());
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebMetaDataAdapter.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebMetaDataAdapter.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebMetaDataAdapter.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -36,6 +36,7 @@
import org.jboss.metadata.WebMetaData;
import org.jboss.metadata.WebSecurityMetaData;
import org.jboss.metadata.WebSecurityMetaData.WebResourceCollection;
+import org.jboss.wsf.framework.deployment.WebXMLRewriter;
import org.jboss.wsf.spi.deployment.Deployment;
import org.jboss.wsf.spi.deployment.UnifiedDeploymentInfo;
import org.jboss.wsf.spi.metadata.j2ee.UnifiedWebMetaData;
@@ -73,18 +74,19 @@
if (contextRoot == null)
contextRoot = wmd.getContextRoot();
- UnifiedWebMetaData umd = new UnifiedWebMetaData();
- umd.setContextRoot(contextRoot);
- umd.setServletMappings(wmd.getServletMappings());
- umd.setServletClassNames(getServletClassMap(wmd));
- umd.setConfigName(wmd.getConfigName());
- umd.setConfigFile(wmd.getConfigFile());
- umd.setSecurityDomain(wmd.getSecurityDomain());
- umd.setPublishLocationAdapter(getPublishLocationAdpater(wmd));
- umd.setSecurityMetaData(getSecurityMetaData(wmd.getSecurityContraints()));
+ UnifiedWebMetaData webMetaData = new UnifiedWebMetaData();
+ webMetaData.setContextRoot(contextRoot);
+ webMetaData.setServletMappings(wmd.getServletMappings());
+ webMetaData.setServletClassNames(getServletClassMap(wmd));
+ webMetaData.setConfigName(wmd.getConfigName());
+ webMetaData.setConfigFile(wmd.getConfigFile());
+ webMetaData.setSecurityDomain(wmd.getSecurityDomain());
+ webMetaData.setPublishLocationAdapter(getPublishLocationAdpater(wmd));
+ webMetaData.setSecurityMetaData(getSecurityMetaData(wmd.getSecurityContraints()));
+
+ dep.getContext().setProperty(WebXMLRewriter.WEBAPP_URL, udi.getUrl());
- dep.getContext().addAttachment(UnifiedWebMetaData.class, umd);
- return umd;
+ return webMetaData;
}
private PublishLocationAdapter getPublishLocationAdpater(final WebMetaData wmd)
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/AbstractDeployerHook.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -68,11 +68,11 @@
return deploymentModelFactory;
}
- public Deployment createDeployment()
+ public Deployment createDeployment(ClassLoader initialLoader)
{
try
{
- return getDeploymentModelFactory().createDeployment();
+ return getDeploymentModelFactory().createDeployment(initialLoader);
}
catch (Exception ex)
{
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -53,9 +53,8 @@
@Override
public Deployment createDeployment(DeploymentUnit unit)
{
- Deployment dep = createDeployment();
+ Deployment dep = createDeployment(unit.getClassLoader());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setInitialClassLoader(unit.getClassLoader());
dep.setRuntimeClassLoader(unit.getClassLoader());
dep.setType(getDeploymentType());
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -56,9 +56,8 @@
@Override
public Deployment createDeployment(DeploymentUnit unit)
{
- Deployment dep = createDeployment();
+ Deployment dep = createDeployment(unit.getClassLoader());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setInitialClassLoader(unit.getClassLoader());
dep.setRuntimeClassLoader(null);
dep.setType(getDeploymentType());
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -55,9 +55,8 @@
@Override
public Deployment createDeployment(DeploymentUnit unit)
{
- Deployment dep = createDeployment();
+ Deployment dep = createDeployment(unit.getClassLoader());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setInitialClassLoader(unit.getClassLoader());
dep.setRuntimeClassLoader(unit.getClassLoader());
dep.setType(getDeploymentType());
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -55,9 +55,8 @@
@Override
public Deployment createDeployment(DeploymentUnit unit)
{
- Deployment dep = createDeployment();
+ Deployment dep = createDeployment(unit.getClassLoader());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot()));
- dep.setInitialClassLoader(unit.getClassLoader());
dep.setRuntimeClassLoader(null);
dep.setType(getDeploymentType());
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeployment.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeployment.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeployment.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -54,11 +54,12 @@
// The runtime class loader
private ClassLoader runtimeLoader;
- BasicDeployment()
+ BasicDeployment(ClassLoader classLoader)
{
context = new BasicDeploymentContext();
- service = new BasicService(this);
state = DeploymentState.UNDEFINED;
+ initialLoader = classLoader;
+ setService(new BasicService());
}
public DeploymentContext getContext()
@@ -108,6 +109,7 @@
public void setService(Service service)
{
+ service.setDeployment(this);
this.service = service;
}
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicService.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicService.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicService.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -45,10 +45,8 @@
private List<Endpoint> endpoints = new LinkedList<Endpoint>();
private String contextRoot;
- BasicService(Deployment dep)
+ BasicService()
{
- this.dep = dep;
- this.dep.setService(this);
}
public Deployment getDeployment()
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DeploymentModelFactoryImpl.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DeploymentModelFactoryImpl.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DeploymentModelFactoryImpl.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -32,14 +32,14 @@
*/
public class DeploymentModelFactoryImpl extends DeploymentModelFactory
{
- public Deployment createDeployment()
+ public Deployment createDeployment(ClassLoader initialLoader)
{
- return new BasicDeployment();
+ return new BasicDeployment(initialLoader);
}
public Service createService()
{
- return new BasicService( createDeployment() );
+ return new BasicService();
}
public Endpoint createEndpoint()
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -29,7 +29,7 @@
*/
public abstract class DeploymentModelFactory implements SPIView
{
- public abstract Deployment createDeployment();
+ public abstract Deployment createDeployment(ClassLoader initialLoader);
public abstract Service createService();
public abstract Endpoint createEndpoint();
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/jaxws/impl/JBossWSProviderImpl.java
===================================================================
---
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/jaxws/impl/JBossWSProviderImpl.java 2007-07-25
19:19:15 UTC (rev 3994)
+++
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/jaxws/impl/JBossWSProviderImpl.java 2007-07-26
08:52:45 UTC (rev 3995)
@@ -114,7 +114,7 @@
UnifiedDeploymentInfo udi = createUDI(endpointClass, loader);
SPIProvider spiProvider = SPIProviderResolver.getInstance().getProvider();
- Deployment dep =
spiProvider.getSPI(DeploymentModelFactory.class).createDeployment();
+ Deployment dep =
spiProvider.getSPI(DeploymentModelFactory.class).createDeployment(loader);
builder.buildWebServiceMetaData(dep, umd, udi, endpointClass, null);
try