diff options
Diffstat (limited to 'sca-java-2.x/trunk/modules/domain-node/src/main')
3 files changed, 13 insertions, 5 deletions
diff --git a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/Node.java b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/Node.java index 5f4e4d3017..9cf0e90d7d 100644 --- a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/Node.java +++ b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/Node.java @@ -72,8 +72,9 @@ public interface Node { String installContribution(Contribution contribution, List<String> dependentContributionURIs, boolean runDeployables) throws ContributionReadException, ActivationException, ValidationException; /** - * Creates an installed contribution from a supplied root contribution. - * See section 10.5.1 of the Assembly Specification. + * Creates an installed contribution from a supplied root contribution URL. + * See section 10.5.1 of the Assembly Specification. This version of + * installContribution automatically runs deployable composites * * @param contributionURL the URL where the contribution is located * @return the URI of the installed contribution @@ -244,7 +245,7 @@ public interface Node { * @param contributionURI the contribution URI * @return the List of deployed composites */ - List<String> getDeployedCompostes(String contributionURI); + List<String> getDeployedComposites(String contributionURI); /** * Get the URIs of all the contributions installed on this Node diff --git a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/NodeFactory.java b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/NodeFactory.java index 153a5341cd..c01befef5d 100644 --- a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/NodeFactory.java +++ b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/NodeFactory.java @@ -86,9 +86,16 @@ public class NodeFactory { protected NodeFactory(Properties config) { init(config); } + + public Node createNode() { + return createNode(null); + } public Node createNode(String domainURI) { - String domainName = getDomainName(domainURI); + String domainName = "default"; + if (domainURI != null){ + domainName = getDomainName(domainURI); + } EndpointRegistry endpointRegistry = domainRegistryFactory.getEndpointRegistry(domainURI, domainName); return new NodeImpl(domainName, deployer, compositeActivator, endpointRegistry, extensionPointRegistry, null); } diff --git a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/NodeImpl.java b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/NodeImpl.java index 19159e96b8..f2dc3bccb0 100644 --- a/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/NodeImpl.java +++ b/sca-java-2.x/trunk/modules/domain-node/src/main/java/org/apache/tuscany/sca/node2/impl/NodeImpl.java @@ -270,7 +270,7 @@ public class NodeImpl implements Node { return domainName; } - public List<String> getDeployedCompostes(String contributionURI) { + public List<String> getDeployedComposites(String contributionURI) { ArrayList<String> compositeURIs = new ArrayList<String>(); InstalledContribution ic = installedContributions.get(contributionURI); if (ic == null) { |