[jboss-cvs] JBossAS SVN: r70096 - trunk/webservices/src/main/org/jboss/wsf/container/jboss50.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Tue Feb 26 08:36:21 EST 2008
Author: thomas.diesler at jboss.com
Date: 2008-02-26 08:36:20 -0500 (Tue, 26 Feb 2008)
New Revision: 70096
Modified:
trunk/webservices/src/main/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java
trunk/webservices/src/main/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java
Log:
More work on endpont API deployment (WIP)
Modified: trunk/webservices/src/main/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java
===================================================================
--- trunk/webservices/src/main/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java 2008-02-26 13:21:36 UTC (rev 70095)
+++ trunk/webservices/src/main/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java 2008-02-26 13:36:20 UTC (rev 70096)
@@ -23,6 +23,8 @@
//$Id: ArchiveDeployerHook.java 4278 2007-08-09 09:13:34Z thomas.diesler at jboss.com $
+import java.net.URL;
+
import org.jboss.deployers.spi.DeploymentException;
import org.jboss.deployers.structure.spi.DeploymentUnit;
import org.jboss.deployers.vfs.spi.structure.VFSDeploymentUnit;
@@ -31,7 +33,6 @@
import org.jboss.wsf.common.DOMUtils;
import org.jboss.wsf.spi.deployment.Deployment;
import org.jboss.wsf.spi.deployment.UnifiedVirtualFile;
-import org.jboss.wsf.spi.deployment.Deployment.DeploymentType;
import org.jboss.wsf.spi.deployment.WSFDeploymentException;
import org.jboss.wsf.spi.metadata.webservices.WebservicesFactory;
import org.jboss.wsf.spi.metadata.webservices.WebservicesMetaData;
@@ -40,8 +41,6 @@
import org.jboss.xb.binding.UnmarshallerFactory;
import org.w3c.dom.Element;
-import java.net.URL;
-
/**
* An abstract web service deployer.
*
@@ -141,7 +140,12 @@
private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit)
{
- VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml");
- return (vf != null ? new VirtualFileAdaptor(vf) : null);
+ UnifiedVirtualFile wsFile = null;
+ if (unit instanceof VFSDeploymentUnit)
+ {
+ VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml");
+ wsFile = vf != null ? new VirtualFileAdaptor(vf) : null;
+ }
+ return wsFile;
}
}
Modified: trunk/webservices/src/main/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java
===================================================================
--- trunk/webservices/src/main/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java 2008-02-26 13:21:36 UTC (rev 70095)
+++ trunk/webservices/src/main/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java 2008-02-26 13:36:20 UTC (rev 70096)
@@ -30,6 +30,8 @@
import org.jboss.deployers.client.spi.DeploymentFactory;
import org.jboss.deployers.spi.attachments.MutableAttachments;
import org.jboss.deployers.spi.structure.ContextInfo;
+import org.jboss.deployers.structure.spi.ClassLoaderFactory;
+import org.jboss.deployers.structure.spi.DeploymentContext;
import org.jboss.deployers.structure.spi.DeploymentUnit;
import org.jboss.logging.Logger;
import org.jboss.metadata.web.jboss.JBossWebMetaData;
@@ -83,6 +85,7 @@
AbstractDeployment deployment = createSimpleDeployment(dep.getSimpleName());
MutableAttachments mutableAttachments = (MutableAttachments)deployment.getPredeterminedManagedObjects();
mutableAttachments.addAttachment(WebMetaDataModifier.PROPERTY_GENERATED_WEBAPP, Boolean.TRUE);
+ mutableAttachments.addAttachment(ClassLoaderFactory.class, new ContextClassLoaderFactory());
mutableAttachments.addAttachment(JBossWebMetaData.class, jbwmd);
mainDeployer.deploy(deployment);
}
@@ -100,4 +103,16 @@
factory.addContext(unit, "");
return unit;
}
+
+ private static class ContextClassLoaderFactory implements ClassLoaderFactory
+ {
+ public ClassLoader createClassLoader(DeploymentContext context) throws Exception
+ {
+ return Thread.currentThread().getContextClassLoader();
+ }
+
+ public void removeClassLoader(DeploymentContext context) throws Exception
+ {
+ }
+ }
}
More information about the jboss-cvs-commits
mailing list