summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/modules/domain-node/src/main/java
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2011-05-15 06:58:46 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2011-05-15 06:58:46 +0000
commit455f83b4a9ea01d1e9f608dbaadf868b7a43d427 (patch)
treed1c0078d9efda21f911d7a56e740953f4dbfad95 /sca-java-2.x/trunk/modules/domain-node/src/main/java
parent36ce29b623082ca132a1734f017df2a7983af26f (diff)
Update to match the Contribution and InstalledContribution interface changes
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1103283 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/domain-node/src/main/java')
-rw-r--r--sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/impl/NodeImpl.java17
1 files changed, 5 insertions, 12 deletions
diff --git a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/impl/NodeImpl.java b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/impl/NodeImpl.java
index 6688a9f2d6..3c0cbe4a83 100644
--- a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/impl/NodeImpl.java
+++ b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/impl/NodeImpl.java
@@ -101,23 +101,18 @@ public class NodeImpl implements Node {
}
public String installContribution(String uri, String contributionURL, String metaDataURL, List<String> dependentContributionURIs, boolean startDeployables) throws ContributionReadException, ActivationException, ValidationException {
- if (uri == null) {
- uri = getDefaultContributionURI(contributionURL);
- }
// TODO: sort out deployables and exports
- org.apache.tuscany.sca.runtime.InstalledContribution ic = new org.apache.tuscany.sca.runtime.InstalledContribution();
- ic.setURI(uri);
- ic.setURL(contributionURL);
+ org.apache.tuscany.sca.runtime.InstalledContribution ic = new org.apache.tuscany.sca.runtime.InstalledContribution(uri, contributionURL);
peekIntoContribution(ic);
endpointRegistry.installContribution(ic);
if (startDeployables) {
for (String compositeURI : ic.getDeployables()) {
- start(uri, compositeURI);
+ start(ic.getURI(), compositeURI);
}
// TODO: sort out metadata and dependents in distributed
- localInstall(uri, contributionURL, metaDataURL, dependentContributionURIs, startDeployables);
+ localInstall(ic.getURI(), contributionURL, metaDataURL, dependentContributionURIs, startDeployables);
}
- return uri;
+ return ic.getURI();
}
/**
@@ -161,9 +156,7 @@ public class NodeImpl implements Node {
throw new ValidationException(e);
}
monitor.analyzeProblems();
- contribution.getDeployables().addAll(metaData.getDeployables());
- contribution.getImports().addAll(metaData.getImports());
- contribution.getExports().addAll(metaData.getExports());
+ contribution.mergeMetaData(metaData);
}
public String installContribution(Contribution contribution, List<String> dependentContributionURIs, boolean startDeployables) throws ContributionReadException, ActivationException, ValidationException {