summaryrefslogtreecommitdiffstats
path: root/java/sca/modules/node-impl/src
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2009-08-28 12:56:21 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2009-08-28 12:56:21 +0000
commit841a47ff38d01ae7a53301ade66584543ca207c3 (patch)
treeeca7b87ef63bf3f76882402e97fca1c2754648f7 /java/sca/modules/node-impl/src
parent70fd3294f83e6fc00af98c9119aabb0df9c4abc5 (diff)
Enable setting configuration on the NodeFactoryImpl
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@808868 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/node-impl/src')
-rw-r--r--java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java
index e81e244458..79b11866b2 100644
--- a/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java
+++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java
@@ -90,6 +90,7 @@ import org.apache.tuscany.sca.definitions.util.DefinitionsUtil;
import org.apache.tuscany.sca.definitions.xml.DefinitionsExtensionPoint;
import org.apache.tuscany.sca.extensibility.ServiceDeclaration;
import org.apache.tuscany.sca.extensibility.ServiceDiscovery;
+import org.apache.tuscany.sca.management.ConfigAttributes;
import org.apache.tuscany.sca.monitor.Monitor;
import org.apache.tuscany.sca.monitor.MonitorFactory;
import org.apache.tuscany.sca.monitor.Problem;
@@ -134,6 +135,7 @@ public class NodeFactoryImpl extends NodeFactory {
* can set this flag.
*/
protected boolean autoDestroy = true;
+ private ConfigAttributes configAttributes;
@Override
public Node createNode(NodeConfiguration configuration) {
@@ -390,6 +392,11 @@ public class NodeFactoryImpl extends NodeFactory {
// Create a monitor
UtilityExtensionPoint utilities = extensionPoints.getExtensionPoint(UtilityExtensionPoint.class);
+
+ if (configAttributes != null) {
+ utilities.addUtility(ConfigAttributes.class, configAttributes);
+ }
+
MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class);
monitor = monitorFactory.createMonitor();
@@ -671,4 +678,11 @@ public class NodeFactoryImpl extends NodeFactory {
return buf.toString();
}
}
+
+ public ConfigAttributes getConfigAttributes() {
+ return configAttributes;
+ }
+ public void setConfigAttributes(ConfigAttributes configAttributes) {
+ this.configAttributes = configAttributes;
+ }
}