summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--sca-java-2.x/trunk/modules/core-spi/src/main/java/org/apache/tuscany/sca/context/CompositeContext.java14
-rw-r--r--sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/DeployedComposite.java2
-rw-r--r--sca-java-2.x/trunk/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java2
3 files changed, 1 insertions, 17 deletions
diff --git a/sca-java-2.x/trunk/modules/core-spi/src/main/java/org/apache/tuscany/sca/context/CompositeContext.java b/sca-java-2.x/trunk/modules/core-spi/src/main/java/org/apache/tuscany/sca/context/CompositeContext.java
index 23a50e5f22..6605ff3fc7 100644
--- a/sca-java-2.x/trunk/modules/core-spi/src/main/java/org/apache/tuscany/sca/context/CompositeContext.java
+++ b/sca-java-2.x/trunk/modules/core-spi/src/main/java/org/apache/tuscany/sca/context/CompositeContext.java
@@ -35,7 +35,7 @@ import org.apache.tuscany.sca.runtime.RuntimeComponentContext;
* @version $Rev$ $Date$
*/
public class CompositeContext {
- protected final static InheritableThreadLocal<CompositeContext> context = new InheritableThreadLocal<CompositeContext>();
+
protected ExtensionPointRegistry extensionPointRegistry;
protected EndpointRegistry endpointRegistry;
protected ComponentContextFactory componentContextFactory;
@@ -84,10 +84,6 @@ public class CompositeContext {
RuntimeComponentContext componentContext = component.getComponentContext();
return componentContext.getCompositeContext();
}
- CompositeContext compositeContext = context.get();
- if (compositeContext != null) {
- return compositeContext;
- }
return null;
}
@@ -124,14 +120,6 @@ public class CompositeContext {
return domainComposite;
}
- public static void setThreadCompositeContext(CompositeContext value) {
- context.set(value);
- }
-
- public static void removeCompositeContext() {
- context.remove();
- }
-
public String getNodeURI() {
return nodeURI;
}
diff --git a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/DeployedComposite.java b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/DeployedComposite.java
index 98c90d5bbc..6e31f283ee 100644
--- a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/DeployedComposite.java
+++ b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/DeployedComposite.java
@@ -102,8 +102,6 @@ public class DeployedComposite {
null, // don't need node uri
deployer.getSystemDefinitions());
- CompositeContext.setThreadCompositeContext(compositeContext); // TODO: what is this doing?
-
compositeActivator.activate(compositeContext, domainComposite);
compositeActivator.start(compositeContext, domainComposite);
diff --git a/sca-java-2.x/trunk/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java b/sca-java-2.x/trunk/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java
index 6eafb4df12..8eecca1564 100644
--- a/sca-java-2.x/trunk/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java
+++ b/sca-java-2.x/trunk/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java
@@ -134,7 +134,6 @@ public class NodeImpl implements Node {
configuration.getURI(),
nodeFactory.getDeployer().getSystemDefinitions());
- CompositeContext.setThreadCompositeContext(compositeContext);
} finally {
// Reset the thread context monitor
nodeFactory.monitorFactory.setContextMonitor(tcm);
@@ -213,7 +212,6 @@ public class NodeImpl implements Node {
this.compositeContext = null;
ThreadMessageContext.removeMessageContext();
- CompositeContext.removeCompositeContext();
} catch (ActivationException e) {
throw new IllegalStateException(e);