Author: thomas.diesler(a)jboss.com
Date: 2007-07-26 22:45:35 -0400 (Thu, 26 Jul 2007)
New Revision: 4011
Added:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicExtendible.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Extendible.java
Removed:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeploymentContext.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentContext.java
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/ApplicationMetaDataAdapterEJB3.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ArchiveDeployerHook.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/InvocationHandlerEJB21.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/JAXWSDeployerHookJSE.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB21.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB3.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/UnifiedDeploymentInfoDeploymentAspect.java
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebAppDeploymentAspect.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/ApplicationMetaDataAdapterEJB21.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB3.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/DeploymentInfoAdapter.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/InvocationHandlerEJB21.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/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ModifyWebMetaDataDeploymentAspect.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB21.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB3.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/UnifiedDeploymentInfoDeploymentAspect.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebMetaDataAdapter.java
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EagerInitializeDeploymentAspect.java
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EndpointServlet.java
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/PublishContractDeploymentAspect.java
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/UnifiedMetaDataDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BackwardCompatibleContextRootDeploymentAspect.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/BasicEndpoint.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/ContextPropertiesDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextRootDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DefaultWebAppDesciptorModifierImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointHandlerDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointNameDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/URLPatternDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppDesciptorModifierImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppGeneratorDeploymentAspect.java
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebXMLRewriterImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Service.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/SunJaxwsDeploymentAspect.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WebAppDesciptorModifierImpl.java
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/DescriptorDeploymentAspect.java
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/WebAppDesciptorModifierImpl.java
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/MetaDataBuilder.java
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCServerMetaDataBuilder.java
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxws/JAXWSMetaDataBuilderEJB3.java
Log:
Add Extendible. Remove DeploymentContext
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/AbstractApplicationMetaDataAdapter.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -46,7 +46,7 @@
public UnifiedApplicationMetaData buildUnifiedApplicationMetaData(Deployment dep,
DeploymentInfo di)
{
ApplicationMetaData apmd = (ApplicationMetaData)di.metaData;
- dep.getContext().addAttachment(ApplicationMetaData.class, apmd);
+ dep.addAttachment(ApplicationMetaData.class, apmd);
UnifiedApplicationMetaData appMetaData = new UnifiedApplicationMetaData();
buildUnifiedBeanMetaData(appMetaData, apmd);
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ApplicationMetaDataAdapterEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -57,7 +57,7 @@
{
UnifiedApplicationMetaData appMetaData = null;
- ObjectName oname = (ObjectName)dep.getContext().getProperty(DEPLOYED_OBJECT);
+ ObjectName oname = (ObjectName)dep.getProperty(DEPLOYED_OBJECT);
// jboss.j2ee:service=EJB3,module=some-ejb3.jar
if (oname != null && oname.getDomain().equals("jboss.j2ee")
&& "EJB3".equals(oname.getKeyProperty("service")))
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ArchiveDeployerHook.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ArchiveDeployerHook.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/ArchiveDeployerHook.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -91,7 +91,7 @@
if (dep == null)
{
dep = createDeployment(unit);
- dep.getContext().addAttachment(DeploymentInfo.class, unit);
+ dep.addAttachment(DeploymentInfo.class, unit);
}
getDeploymentAspectManager().deploy(dep);
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/DeploymentInfoAdapter.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -33,7 +33,6 @@
import org.jboss.metadata.WebMetaData;
import org.jboss.wsf.framework.deployment.WebXMLRewriter;
import org.jboss.wsf.spi.deployment.Deployment;
-import org.jboss.wsf.spi.deployment.DeploymentContext;
import org.jboss.wsf.spi.deployment.Deployment.DeploymentType;
import org.jboss.wsf.spi.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.wsf.spi.metadata.j2ee.UnifiedWebMetaData;
@@ -70,30 +69,28 @@
public void buildDeploymentInfo(Deployment dep, DeploymentInfo di)
{
- DeploymentContext ctx = dep.getContext();
-
- ctx.addAttachment(DeploymentInfo.class, di);
- ctx.setProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT,
di.deployedObject);
+ dep.addAttachment(DeploymentInfo.class, di);
+ dep.setProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT,
di.deployedObject);
if (di.metaData instanceof WebMetaData)
{
UnifiedWebMetaData webMetaData = webMetaDataAdapter.buildUnifiedWebMetaData(dep,
di);
if (webMetaData != null)
- ctx.addAttachment(UnifiedWebMetaData.class, webMetaData);
+ dep.addAttachment(UnifiedWebMetaData.class, webMetaData);
- ctx.setProperty(WebXMLRewriter.WEBAPP_URL, getDeploymentURL(di));
+ dep.setProperty(WebXMLRewriter.WEBAPP_URL, getDeploymentURL(di));
}
else if (dep.getType() == DeploymentType.JAXRPC_EJB3 || dep.getType() ==
DeploymentType.JAXWS_EJB3)
{
UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB3.buildUnifiedApplicationMetaData(dep);
if (appMetaData != null)
- ctx.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
+ dep.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
}
else if (di.metaData instanceof ApplicationMetaData)
{
UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB21.buildUnifiedApplicationMetaData(dep, di);
if (appMetaData != null)
- ctx.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
+ dep.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
}
}
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/InvocationHandlerEJB21.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/InvocationHandlerEJB21.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/InvocationHandlerEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -86,7 +86,7 @@
{
String ejbName = ep.getShortName();
Deployment dep = ep.getService().getDeployment();
- UnifiedApplicationMetaData apMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData apMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
UnifiedBeanMetaData beanMetaData =
(UnifiedBeanMetaData)apMetaData.getBeanByEjbName(ejbName);
if (beanMetaData == null)
throw new WebServiceException("Cannot obtain ejb meta data for: " +
ejbName);
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -70,8 +70,8 @@
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
// Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(ApplicationMetaData.class, appmd);
+ dep.addAttachment(WebservicesMetaData.class, wsMetaData);
+ dep.addAttachment(ApplicationMetaData.class, appmd);
for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
{
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXRPCDeployerHookJSE.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -76,8 +76,8 @@
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
// Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
+ dep.addAttachment(WebservicesMetaData.class, wsMetaData);
+ dep.addAttachment(WebMetaData.class, webMetaData);
for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
{
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/JAXWSDeployerHookJSE.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -71,7 +71,7 @@
throw new IllegalStateException("Deployment unit does not contain web meta
data");
// Copy the attachments
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
+ dep.addAttachment(WebMetaData.class, webMetaData);
List<Servlet> servlets = getRelevantServlets(webMetaData, di.annotationsCl);
for (Servlet servlet : servlets)
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB21.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB21.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -43,7 +43,7 @@
{
public void addSecurityDomain(Element jbossWeb, Deployment dep)
{
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (appMetaData == null)
throw new IllegalStateException("Cannot obtain application meta
data");
@@ -60,7 +60,7 @@
public void addSecurityRoles(Element webApp, Deployment dep)
{
// Fix:
http://jira.jboss.org/jira/browse/JBWS-309
- ApplicationMetaData applMetaData =
dep.getContext().getAttachment(ApplicationMetaData.class);
+ ApplicationMetaData applMetaData = dep.getAttachment(ApplicationMetaData.class);
AssemblyDescriptorMetaData assemblyDescriptor =
applMetaData.getAssemblyDescriptor();
if (assemblyDescriptor != null)
{
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB3.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB3.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/SecurityHandlerEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -50,7 +50,7 @@
{
String securityDomain = null;
- ObjectName deployedObject =
(ObjectName)dep.getContext().getProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT);
+ ObjectName deployedObject =
(ObjectName)dep.getProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT);
Ejb3ModuleMBean ejb3Module = getEJB3Module(deployedObject);
for (Object manager : ejb3Module.getContainers().values())
{
@@ -81,7 +81,7 @@
public void addSecurityRoles(Element webApp, Deployment dep)
{
// The container objects below provide access to all of the ejb metadata
- ObjectName deployedObject =
(ObjectName)dep.getContext().getProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT);
+ ObjectName deployedObject =
(ObjectName)dep.getProperty(ApplicationMetaDataAdapterEJB3.DEPLOYED_OBJECT);
Ejb3ModuleMBean ejb3Module = getEJB3Module(deployedObject);
for (Object manager : ejb3Module.getContainers().values())
{
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/UnifiedDeploymentInfoDeploymentAspect.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/UnifiedDeploymentInfoDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/UnifiedDeploymentInfoDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -45,7 +45,7 @@
@Override
public void create(Deployment dep)
{
- DeploymentInfo di = dep.getContext().getAttachment(DeploymentInfo.class);
+ DeploymentInfo di = dep.getAttachment(DeploymentInfo.class);
if (di == null)
throw new IllegalStateException("Cannot obtain deployment info");
Modified:
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebAppDeploymentAspect.java
===================================================================
---
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebAppDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebAppDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -58,12 +58,12 @@
{
if (dep.getType().toString().endsWith("EJB21") ||
dep.getType().toString().endsWith("EJB3"))
{
- URL warURL = (URL)dep.getContext().getProperty(WebXMLRewriter.WEBAPP_URL);
+ URL warURL = (URL)dep.getProperty(WebXMLRewriter.WEBAPP_URL);
log.debug("publishServiceEndpoint: " + warURL);
try
{
- DeploymentInfo di = dep.getContext().getAttachment(DeploymentInfo.class);
+ DeploymentInfo di = dep.getAttachment(DeploymentInfo.class);
if (di == null)
throw new IllegalStateException("Cannot obtain DeploymentInfo from
context");
@@ -83,7 +83,7 @@
public void destroy(Deployment dep)
{
- URL warURL = (URL)dep.getContext().getProperty(WebXMLRewriter.WEBAPP_URL);
+ URL warURL = (URL)dep.getProperty(WebXMLRewriter.WEBAPP_URL);
if (warURL == null)
{
log.error("Cannot obtain warURL");
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss42/src/main/java/org/jboss/wsf/container/jboss42/WebMetaDataAdapter.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -55,7 +55,7 @@
String contextRoot = null;
WebMetaData wmd = (WebMetaData)di.metaData;
- dep.getContext().addAttachment(WebMetaData.class, wmd);
+ dep.addAttachment(WebMetaData.class, wmd);
if (di.parent != null)
{
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB21.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB21.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -50,7 +50,7 @@
public UnifiedApplicationMetaData buildUnifiedApplicationMetaData(Deployment dep,
DeploymentUnit unit)
{
ApplicationMetaData appMetaData = unit.getAttachment(ApplicationMetaData.class);
- dep.getContext().addAttachment(ApplicationMetaData.class, appMetaData);
+ dep.addAttachment(ApplicationMetaData.class, appMetaData);
UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
buildUnifiedBeanMetaData(umd, appMetaData);
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB3.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB3.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ApplicationMetaDataAdapterEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -53,7 +53,7 @@
public UnifiedApplicationMetaData buildUnifiedApplicationMetaData(Deployment dep,
DeploymentUnit unit)
{
Ejb3Deployment ejb3Deployment = unit.getAttachment(Ejb3Deployment.class);
- dep.getContext().addAttachment(Ejb3Deployment.class, ejb3Deployment);
+ dep.addAttachment(Ejb3Deployment.class, ejb3Deployment);
EjbJarDD jarDD = unit.getAttachment(EjbJarDD.class);
UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ArchiveDeployerHook.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -88,7 +88,7 @@
if (dep == null)
{
dep = createDeployment(unit);
- dep.getContext().addAttachment(DeploymentUnit.class, unit);
+ dep.addAttachment(DeploymentUnit.class, unit);
}
getDeploymentAspectManager().deploy(dep);
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/DeploymentInfoAdapter.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/DeploymentInfoAdapter.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/DeploymentInfoAdapter.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -68,7 +68,7 @@
public void buildDeploymentInfo(Deployment dep, DeploymentUnit unit)
{
- dep.getContext().addAttachment(DeploymentUnit.class, unit);
+ dep.addAttachment(DeploymentUnit.class, unit);
try
{
@@ -77,12 +77,12 @@
{
UnifiedWebMetaData webMetaData =
webMetaDataAdapter.buildUnifiedWebMetaData(dep, unit);
if (webMetaData != null)
- dep.getContext().addAttachment(UnifiedWebMetaData.class, webMetaData);
+ dep.addAttachment(UnifiedWebMetaData.class, webMetaData);
if (dep instanceof ArchiveDeployment)
{
URL webURL = ((ArchiveDeployment)dep).getRootFile().toURL();
- dep.getContext().setProperty(WebXMLRewriter.WEBAPP_URL, webURL);
+ dep.setProperty(WebXMLRewriter.WEBAPP_URL, webURL);
}
}
@@ -91,7 +91,7 @@
{
UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB3.buildUnifiedApplicationMetaData(dep, unit);
if (appMetaData != null)
- dep.getContext().addAttachment(UnifiedApplicationMetaData.class,
appMetaData);
+ dep.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
}
// EJB21 endpoints
@@ -99,7 +99,7 @@
{
UnifiedApplicationMetaData appMetaData =
applicationMetaDataAdapterEJB21.buildUnifiedApplicationMetaData(dep, unit);
if (appMetaData != null)
- dep.getContext().addAttachment(UnifiedApplicationMetaData.class,
appMetaData);
+ dep.addAttachment(UnifiedApplicationMetaData.class, appMetaData);
}
}
catch (RuntimeException rte)
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/InvocationHandlerEJB21.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/InvocationHandlerEJB21.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/InvocationHandlerEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -83,7 +83,7 @@
{
String ejbName = ep.getShortName();
Deployment dep = ep.getService().getDeployment();
- UnifiedApplicationMetaData apMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData apMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
UnifiedBeanMetaData beanMetaData =
(UnifiedBeanMetaData)apMetaData.getBeanByEjbName(ejbName);
if (beanMetaData == null)
throw new WebServiceException("Cannot obtain ejb meta data for: " +
ejbName);
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -70,8 +70,8 @@
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
// Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(ApplicationMetaData.class, appmd);
+ dep.addAttachment(WebservicesMetaData.class, wsMetaData);
+ dep.addAttachment(ApplicationMetaData.class, appmd);
for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
{
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXRPCDeployerHookJSE.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -73,8 +73,8 @@
throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
// Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
+ dep.addAttachment(WebservicesMetaData.class, wsMetaData);
+ dep.addAttachment(WebMetaData.class, webMetaData);
for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
{
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -68,7 +68,7 @@
throw new IllegalStateException("Deployment unit does not contain ejb3
deployment");
// Copy the attachments
- dep.getContext().addAttachment(Ejb3Deployment.class, ejb3Deployment);
+ dep.addAttachment(Ejb3Deployment.class, ejb3Deployment);
Iterator it = ejb3Deployment.getEjbContainers().values().iterator();
while (it.hasNext())
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/JAXWSDeployerHookJSE.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -68,7 +68,7 @@
throw new IllegalStateException("Deployment unit does not contain web meta
data");
// Copy the attachments
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
+ dep.addAttachment(WebMetaData.class, webMetaData);
List<Servlet> servlets = getRelevantServlets(webMetaData,
unit.getClassLoader());
for (Servlet servlet : servlets)
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ModifyWebMetaDataDeploymentAspect.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ModifyWebMetaDataDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/ModifyWebMetaDataDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -49,19 +49,19 @@
public void create(Deployment dep)
{
String propKey = WebAppDesciptorModifier.SERVLET_CLASS;
- String servletClass = (String)dep.getContext().getProperty(propKey);
+ String servletClass = (String)dep.getProperty(propKey);
if (servletClass == null)
throw new IllegalStateException("Cannot obtain context property: " +
propKey);
modifyServletClass(dep, servletClass);
propKey = WebAppDesciptorModifier.SERVLET_CONTEXT_LISTENER;
- String listenerClass = (String)dep.getContext().getProperty(propKey);
+ String listenerClass = (String)dep.getProperty(propKey);
if (listenerClass != null)
modifyListener(dep, listenerClass);
propKey = WebAppDesciptorModifier.CONTEXT_PARAMETER_MAP;
- Map<String, String> contextParams = (Map<String,
String>)dep.getContext().getProperty(propKey);
+ Map<String, String> contextParams = (Map<String,
String>)dep.getProperty(propKey);
if (contextParams != null)
modifyContextParams(dep, contextParams);
}
@@ -69,7 +69,7 @@
private void modifyServletClass(Deployment dep, String servletClass)
{
- WebMetaData webMetaData = dep.getContext().getAttachment(WebMetaData.class);
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
if (webMetaData != null)
{
for (Servlet servlet : webMetaData.getServlets())
@@ -96,7 +96,7 @@
private void modifyListener(Deployment dep, String listenerClass)
{
- WebMetaData webMetaData = dep.getContext().getAttachment(WebMetaData.class);
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
if (webMetaData != null)
{
Listener listener = new Listener();
@@ -107,7 +107,7 @@
private void modifyContextParams(Deployment dep, Map<String, String>
contextParams)
{
- WebMetaData webMetaData = dep.getContext().getAttachment(WebMetaData.class);
+ WebMetaData webMetaData = dep.getAttachment(WebMetaData.class);
if (webMetaData != null)
{
for (Map.Entry<String, String> entry : contextParams.entrySet())
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB21.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB21.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB21.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -43,7 +43,7 @@
{
public void addSecurityDomain(Element jbossWeb, Deployment dep)
{
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (appMetaData == null)
throw new IllegalStateException("Cannot obtain application meta
data");
@@ -60,7 +60,7 @@
public void addSecurityRoles(Element webApp, Deployment dep)
{
// Fix:
http://jira.jboss.org/jira/browse/JBWS-309
- ApplicationMetaData applMetaData =
dep.getContext().getAttachment(ApplicationMetaData.class);
+ ApplicationMetaData applMetaData = dep.getAttachment(ApplicationMetaData.class);
AssemblyDescriptorMetaData assemblyDescriptor =
applMetaData.getAssemblyDescriptor();
if (assemblyDescriptor != null)
{
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB3.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB3.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/SecurityHandlerEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -45,7 +45,7 @@
{
String securityDomain = null;
- Ejb3Deployment ejb3Deployment =
dep.getContext().getAttachment(Ejb3Deployment.class);
+ Ejb3Deployment ejb3Deployment = dep.getAttachment(Ejb3Deployment.class);
if (ejb3Deployment != null)
{
Iterator it = ejb3Deployment.getEjbContainers().values().iterator();
@@ -74,7 +74,7 @@
public void addSecurityRoles(Element webApp, Deployment dep)
{
- Ejb3Deployment ejb3Deployment =
dep.getContext().getAttachment(Ejb3Deployment.class);
+ Ejb3Deployment ejb3Deployment = dep.getAttachment(Ejb3Deployment.class);
if (ejb3Deployment != null)
{
Iterator it = ejb3Deployment.getEjbContainers().values().iterator();
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/UnifiedDeploymentInfoDeploymentAspect.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/UnifiedDeploymentInfoDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/UnifiedDeploymentInfoDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -45,7 +45,7 @@
@Override
public void create(Deployment dep)
{
- DeploymentUnit unit = dep.getContext().getAttachment(DeploymentUnit.class);
+ DeploymentUnit unit = dep.getAttachment(DeploymentUnit.class);
if (unit == null)
throw new IllegalStateException("Cannot obtain deployment unit");
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebAppDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -66,7 +66,7 @@
{
if (dep.getType().toString().endsWith("EJB21") ||
dep.getType().toString().endsWith("EJB3"))
{
- URL warURL = (URL)dep.getContext().getProperty(WebXMLRewriter.WEBAPP_URL);
+ URL warURL = (URL)dep.getProperty(WebXMLRewriter.WEBAPP_URL);
log.debug("publishServiceEndpoint: " + warURL);
try
@@ -87,7 +87,7 @@
public void destroy(Deployment dep)
{
- URL warURL = (URL)dep.getContext().getProperty(WebXMLRewriter.WEBAPP_URL);
+ URL warURL = (URL)dep.getProperty(WebXMLRewriter.WEBAPP_URL);
if (warURL == null)
{
log.error("Cannot obtain warURL");
Modified:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebMetaDataAdapter.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebMetaDataAdapter.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/WebMetaDataAdapter.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -52,7 +52,7 @@
String contextRoot = null;
WebMetaData wmd = unit.getAttachment(WebMetaData.class);
- dep.getContext().addAttachment(WebMetaData.class, wmd);
+ dep.addAttachment(WebMetaData.class, wmd);
if (unit.getParent() != null)
{
Modified:
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EagerInitializeDeploymentAspect.java
===================================================================
---
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EagerInitializeDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EagerInitializeDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -38,7 +38,7 @@
@Override
public void create(Deployment dep)
{
- UnifiedMetaData umd = dep.getContext().getAttachment(UnifiedMetaData.class);
+ UnifiedMetaData umd = dep.getAttachment(UnifiedMetaData.class);
if (umd == null)
throw new IllegalStateException("Cannot obtain unified meta data");
Modified:
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EndpointServlet.java
===================================================================
---
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EndpointServlet.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/EndpointServlet.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -105,7 +105,7 @@
if (dep.getType() == DeploymentType.JAXRPC_JSE || dep.getType() ==
DeploymentType.JAXWS_JSE)
{
// Initialize the meta data model
- UnifiedMetaData umd = dep.getContext().getAttachment(UnifiedMetaData.class);
+ UnifiedMetaData umd = dep.getAttachment(UnifiedMetaData.class);
if (umd.isEagerInitialized() == false)
{
umd.setClassLoader(dep.getRuntimeClassLoader());
Modified:
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/PublishContractDeploymentAspect.java
===================================================================
---
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/PublishContractDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/PublishContractDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -42,7 +42,7 @@
@Override
public void create(Deployment dep)
{
- UnifiedMetaData umd = dep.getContext().getAttachment(UnifiedMetaData.class);
+ UnifiedMetaData umd = dep.getAttachment(UnifiedMetaData.class);
if (umd == null)
throw new IllegalStateException("Cannot obtain unified meta data");
Modified:
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/UnifiedMetaDataDeploymentAspect.java
===================================================================
---
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/UnifiedMetaDataDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/native/src/main/java/org/jboss/wsf/stack/jbws/UnifiedMetaDataDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -47,7 +47,7 @@
@Override
public void create(Deployment dep)
{
- UnifiedMetaData umd = dep.getContext().getAttachment(UnifiedMetaData.class);
+ UnifiedMetaData umd = dep.getAttachment(UnifiedMetaData.class);
if (umd == null)
{
if (dep.getType() == DeploymentType.JAXRPC_JSE)
@@ -75,7 +75,7 @@
throw new IllegalStateException("Invalid type: " +
dep.getType());
}
- dep.getContext().addAttachment(UnifiedMetaData.class, umd);
+ dep.addAttachment(UnifiedMetaData.class, umd);
}
for (Endpoint ep : dep.getService().getEndpoints())
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BackwardCompatibleContextRootDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BackwardCompatibleContextRootDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BackwardCompatibleContextRootDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -72,7 +72,7 @@
{
String urlPattern = null;
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (appMetaData != null && appMetaData.getBeanByEjbName(ep.getShortName())
!= null)
{
UnifiedBeanMetaData bmd = appMetaData.getBeanByEjbName(ep.getShortName());
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeployment.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -22,7 +22,6 @@
package org.jboss.wsf.framework.deployment;
import org.jboss.wsf.spi.deployment.Deployment;
-import org.jboss.wsf.spi.deployment.DeploymentContext;
import org.jboss.wsf.spi.deployment.Service;
//$Id$
@@ -35,10 +34,8 @@
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public class BasicDeployment implements Deployment
+public class BasicDeployment extends BasicExtendible implements Deployment
{
- // The context for this deployment dep
- private DeploymentContext context;
// The name for this deployment
private String simpleName;
// A deployment has one service
@@ -55,22 +52,11 @@
BasicDeployment(String name, ClassLoader classLoader)
{
simpleName = name;
- context = new BasicDeploymentContext();
state = DeploymentState.UNDEFINED;
initialLoader = classLoader;
setService(new BasicService());
}
- public DeploymentContext getContext()
- {
- return context;
- }
-
- public void setContext(DeploymentContext context)
- {
- this.context = context;
- }
-
public String getSimpleName()
{
return simpleName;
Deleted:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeploymentContext.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeploymentContext.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicDeploymentContext.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -1,77 +0,0 @@
-/*
- * 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.framework.deployment;
-
-//$Id$
-
-import org.jboss.wsf.spi.deployment.DeploymentContext;
-
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * A general web service deployment context.
- *
- * @author Thomas.Diesler(a)jboss.com
- * @since 20-Apr-2007
- */
-public class BasicDeploymentContext implements DeploymentContext
-{
- private Map<Class, Object> attachments = new HashMap<Class, Object>();
- private Map<String, Object> properties = new HashMap<String, Object>();
-
- public <T> T getAttachment(Class<T> clazz)
- {
- return (T)attachments.get(clazz);
- }
-
- public <T> T addAttachment(Class<T> clazz, Object obj)
- {
- return (T)attachments.put(clazz, obj);
- }
-
- public <T> T removeAttachment(Class<T> key)
- {
- return (T)attachments.remove(key);
- }
-
- public Set<String> getProperties()
- {
- return properties.keySet();
- }
-
- public Object getProperty(String key)
- {
- return properties.get(key);
- }
-
- public void removeProperty(String key)
- {
- properties.remove(key);
- }
-
- public void setProperty(String key, Object value)
- {
- properties.put(key, value);
- }
-}
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicEndpoint.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicEndpoint.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicEndpoint.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -21,25 +21,28 @@
*/
package org.jboss.wsf.framework.deployment;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+import javax.management.ObjectName;
+
import org.jboss.wsf.spi.binding.BindingCustomization;
-import org.jboss.wsf.spi.invocation.InvocationHandler;
-import org.jboss.wsf.spi.invocation.RequestHandler;
-import org.jboss.wsf.spi.management.EndpointMetrics;
import org.jboss.wsf.spi.deployment.Endpoint;
-import org.jboss.wsf.spi.deployment.Service;
import org.jboss.wsf.spi.deployment.LifecycleHandler;
+import org.jboss.wsf.spi.deployment.Service;
import org.jboss.wsf.spi.deployment.WSFDeploymentException;
+import org.jboss.wsf.spi.invocation.InvocationHandler;
+import org.jboss.wsf.spi.invocation.RequestHandler;
+import org.jboss.wsf.spi.management.EndpointMetrics;
-import javax.management.ObjectName;
-import java.util.*;
-
/**
* A general JAXWS endpoint.
*
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public class BasicEndpoint implements Endpoint
+public class BasicEndpoint extends BasicExtendible implements Endpoint
{
private Service service;
private ObjectName name;
@@ -50,8 +53,6 @@
private RequestHandler requestHandler;
private InvocationHandler invocationHandler;
private LifecycleHandler lifecycleHandler;
- private Map<Class, Object> attachments = new HashMap<Class, Object>();
- private Map<String, Object> properties = new HashMap<String, Object>();
private EndpointMetrics metrics;
private List<BindingCustomization> bindingCustomizsations = new
ArrayList<BindingCustomization>();
private String address;
@@ -220,41 +221,6 @@
bindingCustomizsations.add(customization);
}
- public <T> T addAttachment(Class<T> key, Object value)
- {
- return (T)attachments.put(key, value);
- }
-
- public <T> T getAttachment(Class<T> key)
- {
- return (T)attachments.get(key);
- }
-
- public <T> T removeAttachment(Class<T> key)
- {
- return (T)attachments.get(key);
- }
-
- public Set<String> getProperties()
- {
- return properties.keySet();
- }
-
- public Object getProperty(String key)
- {
- return properties.get(key);
- }
-
- public void removeProperty(String key)
- {
- properties.remove(key);
- }
-
- public void setProperty(String key, Object value)
- {
- properties.put(key, value);
- }
-
public EndpointMetrics getEndpointMetrics()
{
return metrics;
Added:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicExtendible.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicExtendible.java
(rev 0)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicExtendible.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -0,0 +1,77 @@
+/*
+ * 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.framework.deployment;
+
+//$Id: BasicDeploymentContext.java 3959 2007-07-20 14:44:19Z heiko.braun(a)jboss.com $
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
+
+import org.jboss.wsf.spi.deployment.Extendible;
+
+/**
+ * A general extendible artifact
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 20-Apr-2007
+ */
+public class BasicExtendible implements Extendible
+{
+ private Map<Class, Object> attachments = new HashMap<Class, Object>();
+ private Map<String, Object> properties = new HashMap<String, Object>();
+
+ public <T> T getAttachment(Class<T> clazz)
+ {
+ return (T)attachments.get(clazz);
+ }
+
+ public <T> T addAttachment(Class<T> clazz, Object obj)
+ {
+ return (T)attachments.put(clazz, obj);
+ }
+
+ public <T> T removeAttachment(Class<T> key)
+ {
+ return (T)attachments.remove(key);
+ }
+
+ public Set<String> getProperties()
+ {
+ return properties.keySet();
+ }
+
+ public Object getProperty(String key)
+ {
+ return properties.get(key);
+ }
+
+ public void removeProperty(String key)
+ {
+ properties.remove(key);
+ }
+
+ public void setProperty(String key, Object value)
+ {
+ properties.put(key, value);
+ }
+}
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-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/BasicService.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -39,7 +39,7 @@
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public class BasicService implements Service
+public class BasicService extends BasicExtendible implements Service
{
private Deployment dep;
private List<Endpoint> endpoints = new LinkedList<Endpoint>();
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextPropertiesDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextPropertiesDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextPropertiesDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -57,7 +57,7 @@
{
String key = it.next();
String value = contextProperties.get(key);
- dep.getContext().setProperty(key, value);
+ dep.setProperty(key, value);
}
}
}
\ No newline at end of file
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextRootDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextRootDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/ContextRootDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -62,7 +62,7 @@
String contextRoot = null;
// #1 Use the explicit context root from the web meta data
- UnifiedWebMetaData webMetaData =
dep.getContext().getAttachment(UnifiedWebMetaData.class);
+ UnifiedWebMetaData webMetaData = dep.getAttachment(UnifiedWebMetaData.class);
if (webMetaData != null)
contextRoot = webMetaData.getContextRoot();
@@ -84,7 +84,7 @@
}
// #3 Use the explicit context root from webservices/context-root
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (contextRoot == null && appMetaData != null)
{
contextRoot = appMetaData.getWebServiceContextRoot();
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DefaultWebAppDesciptorModifierImpl.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DefaultWebAppDesciptorModifierImpl.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/DefaultWebAppDesciptorModifierImpl.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -47,12 +47,12 @@
Element root = webXml.getRootElement();
String propKey = SERVLET_CLASS;
- String servletClass = (String)dep.getContext().getProperty(propKey);
+ String servletClass = (String)dep.getProperty(propKey);
if (servletClass == null)
throw new IllegalStateException("Cannot obtain context property: " +
propKey);
propKey = CONTEXT_PARAMETER_MAP;
- Map<String, String> contextParams = (Map<String,
String>)dep.getContext().getProperty(propKey);
+ Map<String, String> contextParams = (Map<String,
String>)dep.getProperty(propKey);
if (contextParams != null)
{
for (Map.Entry<String, String> entry : contextParams.entrySet())
@@ -64,7 +64,7 @@
}
propKey = SERVLET_CONTEXT_LISTENER;
- String listenerClass = (String)dep.getContext().getProperty(propKey);
+ String listenerClass = (String)dep.getProperty(propKey);
if (listenerClass != null)
{
Element listener = root.addElement("listener");
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointHandlerDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointHandlerDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointHandlerDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -89,7 +89,7 @@
String key = dep.getType().toString();
// Use a special key for MDB endpoints
- UnifiedApplicationMetaData uapp =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData uapp =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (uapp != null)
{
UnifiedBeanMetaData bmd = uapp.getBeanByEjbName(ep.getShortName());
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointNameDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointNameDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/EndpointNameDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -53,7 +53,7 @@
name.append(Endpoint.SEPID_PROPERTY_ENDPOINT + "=" +
ep.getShortName());
// Append the JMS destination, for an MDB endpoint
- UnifiedApplicationMetaData uapp =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData uapp =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (uapp != null)
{
UnifiedBeanMetaData bmd = uapp.getBeanByEjbName(ep.getShortName());
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/URLPatternDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/URLPatternDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/URLPatternDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -66,7 +66,7 @@
String urlPattern = null;
// #1 For JSE lookup the url-pattern from the servlet mappings
- UnifiedWebMetaData webMetaData =
dep.getContext().getAttachment(UnifiedWebMetaData.class);
+ UnifiedWebMetaData webMetaData = dep.getAttachment(UnifiedWebMetaData.class);
if (webMetaData != null)
{
String epName = ep.getShortName();
@@ -76,7 +76,7 @@
}
// #2 Use the explicit urlPattern from port-component/port-component-uri
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (appMetaData != null && appMetaData.getBeanByEjbName(ep.getShortName())
!= null)
{
UnifiedBeanMetaData bmd = appMetaData.getBeanByEjbName(ep.getShortName());
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppDesciptorModifierImpl.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppDesciptorModifierImpl.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppDesciptorModifierImpl.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -47,12 +47,12 @@
Element root = webXml.getRootElement();
String propKey = SERVLET_CLASS;
- String servletClass = (String)dep.getContext().getProperty(propKey);
+ String servletClass = (String)dep.getProperty(propKey);
if (servletClass == null)
throw new IllegalStateException("Cannot obtain context property: " +
propKey);
propKey = CONTEXT_PARAMETER_MAP;
- Map<String, String> contextParams = (Map<String,
String>)dep.getContext().getProperty(propKey);
+ Map<String, String> contextParams = (Map<String,
String>)dep.getProperty(propKey);
if (contextParams != null)
{
for (Map.Entry<String, String> entry : contextParams.entrySet())
@@ -64,7 +64,7 @@
}
propKey = SERVLET_CONTEXT_LISTENER;
- String listenerClass = (String)dep.getContext().getProperty(propKey);
+ String listenerClass = (String)dep.getProperty(propKey);
if (listenerClass != null)
{
Element listener = root.addElement("listener");
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppGeneratorDeploymentAspect.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppGeneratorDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebAppGeneratorDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -76,12 +76,12 @@
if (dep.getType().toString().endsWith("EJB21"))
{
URL webAppURL = generatWebDeployment((ArchiveDeployment)dep,
securityHandlerEJB21);
- dep.getContext().setProperty(WebXMLRewriter.WEBAPP_URL, webAppURL);
+ dep.setProperty(WebXMLRewriter.WEBAPP_URL, webAppURL);
}
else if (dep.getType().toString().endsWith("EJB3"))
{
URL webAppURL = generatWebDeployment((ArchiveDeployment)dep,
securityHandlerEJB3);
- dep.getContext().setProperty(WebXMLRewriter.WEBAPP_URL, webAppURL);
+ dep.setProperty(WebXMLRewriter.WEBAPP_URL, webAppURL);
}
}
@@ -180,7 +180,7 @@
secureWSDLAccess = anWebContext.secureWSDLAccess();
}
- UnifiedApplicationMetaData appMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData appMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (appMetaData != null && appMetaData.getBeanByEjbName(ejbName) !=
null)
{
UnifiedBeanMetaData bmd = appMetaData.getBeanByEjbName(ejbName);
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebXMLRewriterImpl.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebXMLRewriterImpl.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/deployment/WebXMLRewriterImpl.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -63,7 +63,7 @@
public RewriteResults rewriteWebXml(Deployment dep)
{
- URL warURL = (URL)dep.getContext().getProperty(WebXMLRewriter.WEBAPP_URL);
+ URL warURL = (URL)dep.getProperty(WebXMLRewriter.WEBAPP_URL);
File warFile = new File(warURL.getFile());
if (warFile.isDirectory() == false)
throw new WebServiceException("Expected a war directory: " + warURL);
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -31,7 +31,7 @@
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public interface Deployment
+public interface Deployment extends Extendible
{
public enum DeploymentType
{
@@ -61,12 +61,6 @@
/** Set the runtime class loader for this deployment */
void setRuntimeClassLoader(ClassLoader loader);
- /** Get the deployment context */
- DeploymentContext getContext();
-
- /** Set the deployment context */
- void setContext(DeploymentContext context);
-
/** Get the deployment type */
DeploymentType getType();
Deleted:
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentContext.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentContext.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/DeploymentContext.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -1,50 +0,0 @@
-/*
- * 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.spi.deployment;
-
-// $Id$
-
-import java.util.Set;
-
-public interface DeploymentContext
-{
- /** Add arbitrary attachments */
- <T> T addAttachment(Class<T> key, Object value);
-
- /** Get arbitrary attachments */
- <T> T getAttachment(Class<T> key);
-
- /** Remove arbitrary attachments */
- <T> T removeAttachment(Class<T> key);
-
- /** Get an context property */
- Object getProperty(String key);
-
- /** Set an context property */
- void setProperty(String key, Object value);
-
- /** Remove an context property */
- void removeProperty(String key);
-
- /** Get the set of context property names */
- Set<String> getProperties();
-}
\ No newline at end of file
Modified: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -38,7 +38,7 @@
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public interface Endpoint
+public interface Endpoint extends Extendible
{
static final String SEPID_DOMAIN = "jboss.ws";
static final String SEPID_PROPERTY_CONTEXT = "context";
@@ -117,7 +117,7 @@
/** Get all binding customizations for this endpoint */
List<BindingCustomization> getBindingCustomizations();
- /* Get a concrete binding customization */
+ /** Get a concrete binding customization */
BindingCustomization getBindingCustomization(BindingCustomization
bindingCustomization);
/** Add a binding customization to this endpoint*/
@@ -128,25 +128,4 @@
/** Set the endpoint metrics for this endpoint */
void setEndpointMetrics(EndpointMetrics metrics);
-
- /** Add arbitrary attachments */
- <T> T addAttachment(Class<T> key, Object value);
-
- /** Get arbitrary attachments */
- <T> T getAttachment(Class<T> key);
-
- /** Remove arbitrary attachments */
- <T> T removeAttachment(Class<T> key);
-
- /** Get an endpoint property */
- Object getProperty(String key);
-
- /** Set an endpoint property */
- void setProperty(String key, Object value);
-
- /** Remove an endpoint property */
- void removeProperty(String key);
-
- /** Get the set of endpoint property names */
- Set<String> getProperties();
}
Added: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Extendible.java
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Extendible.java
(rev 0)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Extendible.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -0,0 +1,56 @@
+/*
+ * 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.spi.deployment;
+
+//$Id: Deployment.java 3999 2007-07-26 11:33:20Z thomas.diesler(a)jboss.com $
+
+import java.util.Set;
+
+/**
+ * A general extendible artifact
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 20-Apr-2007
+ */
+public interface Extendible
+{
+ /** Add arbitrary attachments */
+ <T> T addAttachment(Class<T> key, Object value);
+
+ /** Get arbitrary attachments */
+ <T> T getAttachment(Class<T> key);
+
+ /** Remove arbitrary attachments */
+ <T> T removeAttachment(Class<T> key);
+
+ /** Get an context property */
+ Object getProperty(String key);
+
+ /** Set an context property */
+ void setProperty(String key, Object value);
+
+ /** Remove an context property */
+ void removeProperty(String key);
+
+ /** Get the set of context property names */
+ Set<String> getProperties();
+}
\ No newline at end of file
Modified: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Service.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Service.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/Service.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -34,7 +34,7 @@
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
-public interface Service
+public interface Service extends Extendible
{
/** Get the deployment this service belongs to */
Deployment getDeployment();
Modified:
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/SunJaxwsDeploymentAspect.java
===================================================================
---
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/SunJaxwsDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/SunJaxwsDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -48,7 +48,7 @@
public void create(Deployment dep)
{
- DDEndpoints dd = dep.getContext().getAttachment(DDEndpoints.class);
+ DDEndpoints dd = dep.getAttachment(DDEndpoints.class);
if (dd == null)
{
dd = new DDEndpoints();
@@ -74,14 +74,14 @@
dd.addEndpoint(ddep);
}
- dep.getContext().addAttachment(DDEndpoints.class, dd);
+ dep.addAttachment(DDEndpoints.class, dd);
String propKey = WebAppDesciptorModifier.CONTEXT_PARAMETER_MAP;
- Map<String, String> contextParams = (Map<String,
String>)dep.getContext().getProperty(propKey);
+ Map<String, String> contextParams = (Map<String,
String>)dep.getProperty(propKey);
if (contextParams == null)
{
contextParams = new HashMap<String, String>();
- dep.getContext().setProperty(propKey, contextParams);
+ dep.setProperty(propKey, contextParams);
}
contextParams.put(WSServletContextListenerJBWS.PARAM_SUN_JAXWS_URL,
dd.createFileURL().toExternalForm());
}
@@ -90,7 +90,7 @@
@Override
public void destroy(Deployment dep)
{
- DDEndpoints dd = dep.getContext().getAttachment(DDEndpoints.class);
+ DDEndpoints dd = dep.getAttachment(DDEndpoints.class);
if (dd != null)
{
dd.destroyFileURL();
Modified:
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WebAppDesciptorModifierImpl.java
===================================================================
---
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WebAppDesciptorModifierImpl.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WebAppDesciptorModifierImpl.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -71,7 +71,7 @@
Element root = webXml.getRootElement();
- DDEndpoints ddSunJaxws = dep.getContext().getAttachment(DDEndpoints.class);
+ DDEndpoints ddSunJaxws = dep.getAttachment(DDEndpoints.class);
if (ddSunJaxws == null)
throw new IllegalStateException("Cannot obtain sun-jaxws meta data");
Modified:
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/DescriptorDeploymentAspect.java
===================================================================
---
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/DescriptorDeploymentAspect.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/DescriptorDeploymentAspect.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -104,14 +104,14 @@
dd.addBean(bean);
}
- dep.getContext().addAttachment(DDBeans.class, dd);
+ dep.addAttachment(DDBeans.class, dd);
String propKey = WebAppDesciptorModifier.CONTEXT_PARAMETER_MAP;
- Map<String, String> contextParams = (Map<String,
String>)dep.getContext().getProperty(propKey);
+ Map<String, String> contextParams = (Map<String,
String>)dep.getProperty(propKey);
if (contextParams == null)
{
contextParams = new HashMap<String, String>();
- dep.getContext().setProperty(propKey, contextParams);
+ dep.setProperty(propKey, contextParams);
}
contextParams.put(CXFServletExt.PARAM_CXF_BEANS_URL,
dd.createFileURL().toExternalForm());
}
@@ -119,7 +119,7 @@
@Override
public void destroy(Deployment dep)
{
- DDBeans dd = dep.getContext().getAttachment(DDBeans.class);
+ DDBeans dd = dep.getAttachment(DDBeans.class);
if (dd != null)
{
dd.destroyFileURL();
Modified:
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/WebAppDesciptorModifierImpl.java
===================================================================
---
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/WebAppDesciptorModifierImpl.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/integration/xfire/src/main/java/org/jboss/wsf/stack/xfire/WebAppDesciptorModifierImpl.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -60,7 +60,7 @@
Element root = webXml.getRootElement();
- DDBeans ddbeans = dep.getContext().getAttachment(DDBeans.class);
+ DDBeans ddbeans = dep.getAttachment(DDBeans.class);
if (ddbeans == null)
throw new IllegalStateException("Cannot obtain sun-jaxws meta data");
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/MetaDataBuilder.java
===================================================================
---
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/MetaDataBuilder.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/MetaDataBuilder.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -186,7 +186,7 @@
idstr.append("," + ServerEndpointMetaData.SEPID_PROPERTY_ENDPOINT +
"=" + linkName);
// Add JMS destination JNDI name for MDB endpoints
- UnifiedApplicationMetaData apMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData apMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
if (apMetaData != null)
{
String ejbName = sepMetaData.getLinkName();
@@ -246,7 +246,7 @@
protected void initTransportGuaranteeJSE(Deployment dep, ServerEndpointMetaData
sepMetaData, String servletLink) throws IOException
{
String transportGuarantee = null;
- UnifiedWebMetaData webMetaData =
dep.getContext().getAttachment(UnifiedWebMetaData.class);
+ UnifiedWebMetaData webMetaData = dep.getAttachment(UnifiedWebMetaData.class);
if (webMetaData != null)
{
Map<String, String> servletMappings = webMetaData.getServletMappings();
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCServerMetaDataBuilder.java
===================================================================
---
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCServerMetaDataBuilder.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCServerMetaDataBuilder.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -78,7 +78,7 @@
wsMetaData.setDeploymentName(dep.getCanonicalName());
wsMetaData.setClassLoader(dep.getInitialClassLoader());
- WebservicesMetaData jaxrpcMapping =
dep.getContext().getAttachment(WebservicesMetaData.class);
+ WebservicesMetaData jaxrpcMapping =
dep.getAttachment(WebservicesMetaData.class);
WebserviceDescriptionMetaData[] wsDescriptionArr =
jaxrpcMapping.getWebserviceDescriptions();
for (WebserviceDescriptionMetaData wsdMetaData : wsDescriptionArr)
{
@@ -144,8 +144,8 @@
initEndpointAddress(dep, sepMetaData);
- UnifiedApplicationMetaData apMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
- UnifiedWebMetaData webMetaData =
dep.getContext().getAttachment(UnifiedWebMetaData.class);
+ UnifiedApplicationMetaData apMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedWebMetaData webMetaData =
dep.getAttachment(UnifiedWebMetaData.class);
if (apMetaData != null)
{
wsMetaData.setSecurityDomain(apMetaData.getSecurityDomain());
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxws/JAXWSMetaDataBuilderEJB3.java
===================================================================
---
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxws/JAXWSMetaDataBuilderEJB3.java 2007-07-26
19:38:33 UTC (rev 4010)
+++
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxws/JAXWSMetaDataBuilderEJB3.java 2007-07-27
02:45:35 UTC (rev 4011)
@@ -61,7 +61,7 @@
wsMetaData.setClassLoader(dep.getInitialClassLoader());
// The container objects below provide access to all of the ejb metadata
- UnifiedApplicationMetaData apMetaData =
dep.getContext().getAttachment(UnifiedApplicationMetaData.class);
+ UnifiedApplicationMetaData apMetaData =
dep.getAttachment(UnifiedApplicationMetaData.class);
Iterator<UnifiedBeanMetaData> it = apMetaData.getEnterpriseBeans();
while (it.hasNext())
{