Author: heiko.braun(a)jboss.com
Date: 2008-05-07 07:39:59 -0400 (Wed, 07 May 2008)
New Revision: 6930
Modified:
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployer/JAXRPCDeployerHookEJB21.java
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployment/metadata/ContainerMetaDataAdapter.java
Log:
Fix NPE in JAXRPC deployments
Modified:
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployer/JAXRPCDeployerHookEJB21.java
===================================================================
---
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployer/JAXRPCDeployerHookEJB21.java 2008-05-07
10:38:05 UTC (rev 6929)
+++
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployer/JAXRPCDeployerHookEJB21.java 2008-05-07
11:39:59 UTC (rev 6930)
@@ -32,6 +32,7 @@
import org.jboss.wsf.spi.deployment.Deployment;
import org.jboss.wsf.spi.deployment.Endpoint;
import org.jboss.wsf.spi.deployment.Service;
+import org.jboss.wsf.spi.deployment.integration.WebServiceDeployment;
import org.jboss.wsf.spi.deployment.Deployment.DeploymentType;
import org.jboss.wsf.spi.metadata.webservices.PortComponentMetaData;
import org.jboss.wsf.spi.metadata.webservices.WebserviceDescriptionMetaData;
@@ -70,9 +71,14 @@
if (wsMetaData == null)
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
+ WebServiceDeployment webServiceDeployment =
unit.getAttachment(WebServiceDeployment.class);
+ if (webServiceDeployment == null)
+ throw new IllegalStateException("Deployment unit does not contain
webServiceDeployment");
+
// Copy the attachments
dep.addAttachment(WebservicesMetaData.class, wsMetaData);
dep.addAttachment(JBossMetaData.class, jbmd);
+ dep.addAttachment(WebServiceDeployment.class, webServiceDeployment);
for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
{
Modified:
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployment/metadata/ContainerMetaDataAdapter.java
===================================================================
---
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployment/metadata/ContainerMetaDataAdapter.java 2008-05-07
10:38:05 UTC (rev 6929)
+++
container/jboss50/branches/jbossws-jboss501/src/main/java/org/jboss/wsf/container/jboss50/deployment/metadata/ContainerMetaDataAdapter.java 2008-05-07
11:39:59 UTC (rev 6930)
@@ -24,12 +24,12 @@
//$Id$
import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.ejb3.Ejb3Deployment;
import org.jboss.logging.Logger;
import org.jboss.metadata.ejb.jboss.JBossMetaData;
import org.jboss.metadata.web.jboss.JBossWebMetaData;
import org.jboss.wsf.spi.deployment.ArchiveDeployment;
import org.jboss.wsf.spi.deployment.Deployment;
-import org.jboss.wsf.spi.deployment.integration.WebServiceDeployment;
import org.jboss.wsf.spi.metadata.j2ee.EJBArchiveMetaData;
import org.jboss.wsf.spi.metadata.j2ee.JSEArchiveMetaData;
import org.jboss.wsf.spi.transport.HttpSpec;
@@ -87,7 +87,7 @@
}
// EJB3 endpoints
- else if (unit.getAttachment(WebServiceDeployment.class) != null)
+ else if (unit.getAttachment(Ejb3Deployment.class) != null)
{
EJBArchiveMetaData ejbMetaData = ejbMetaDataAdapterEJB3.buildMetaData(dep,
unit);
if (ejbMetaData != null)
Show replies by date