diff options
154 files changed, 847 insertions, 367 deletions
diff --git a/java/sca/distribution/bundle/pom.xml b/java/sca/distribution/bundle/pom.xml index 9a72908c41..3273e3b9ed 100644 --- a/java/sca/distribution/bundle/pom.xml +++ b/java/sca/distribution/bundle/pom.xml @@ -381,17 +381,17 @@ </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>${pom.version}</version> </dependency> <dependency> diff --git a/java/sca/distribution/manifest/pom.xml b/java/sca/distribution/manifest/pom.xml index 015dec667f..9e56624f72 100644 --- a/java/sca/distribution/manifest/pom.xml +++ b/java/sca/distribution/manifest/pom.xml @@ -459,17 +459,17 @@ </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>${pom.version}</version> </dependency> <dependency> diff --git a/java/sca/itest/callablereferences/pom.xml b/java/sca/itest/callablereferences/pom.xml index f9deb7b230..5fbf05c6e7 100644 --- a/java/sca/itest/callablereferences/pom.xml +++ b/java/sca/itest/callablereferences/pom.xml @@ -45,7 +45,7 @@ <!-- <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> <scope>test</scope> </dependency> diff --git a/java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java b/java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java index 053047f42f..ba9020811c 100644 --- a/java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java +++ b/java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java @@ -27,8 +27,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
@@ -40,8 +40,8 @@ import org.junit.Test; */
public class CallableReferenceRemoteTestCase {
- private static SCANode2 nodeA;
- private static SCANode2 nodeB;
+ private static SCANode nodeA;
+ private static SCANode nodeB;
private static AComponent acomponent;
@@ -52,7 +52,7 @@ public class CallableReferenceRemoteTestCase { System.out.println("Setting up nodes");
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
nodeA = nodeFactory.createSCANode(new File("src/main/resources/nodeA/CompositeA.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/nodeA").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/pom.xml b/java/sca/itest/conversations-ws/pom.xml index a8b07c81bb..87827c86dd 100644 --- a/java/sca/itest/conversations-ws/pom.xml +++ b/java/sca/itest/conversations-ws/pom.xml @@ -33,7 +33,7 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-impl</artifactId>
+ <artifactId>tuscany-node-impl</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java index d05e4712a1..9df966ebc2 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java @@ -26,8 +26,8 @@ import java.io.File; import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
@@ -35,12 +35,12 @@ import org.junit.Test; public class ConversationWSDLTestCase {
- private SCANode2 node;
+ private SCANode node;
private ConversationalClient conversationalStatelessClientStatefulService;
@Before
public void setUp() throws Exception {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/ConversationalWSDL/conversationalWSDL.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/ConversationalWSDL").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java index 7eec461476..ebd1e55dac 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java @@ -31,15 +31,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class NonConversationalCallbackTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -50,7 +50,7 @@ public class NonConversationalCallbackTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java index 39ab4319f7..2c16145f54 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java @@ -32,15 +32,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class RequestScopeTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -51,7 +51,7 @@ public class RequestScopeTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java index 28df937283..4166e6acdf 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java @@ -31,15 +31,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class StatefulStatefulTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -50,7 +50,7 @@ public class StatefulStatefulTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java index 02295b0ca6..6023b7cd53 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java @@ -31,15 +31,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class StatefulStatelessTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -50,7 +50,7 @@ public class StatefulStatelessTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java index fce6ee0d50..fb3a3cec6f 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java @@ -30,15 +30,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class StatelessStatefulTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -49,7 +49,7 @@ public class StatelessStatefulTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java index 6df7767823..5fbe2c3f69 100644 --- a/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java +++ b/java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java @@ -30,15 +30,15 @@ import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceSta import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl;
import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
public class StatelessStatelessTestCase {
- private static SCANode2 node;
+ private static SCANode node;
private static ConversationalClient conversationalStatelessClientStatelessService;
private static ConversationalClient conversationalStatelessClientStatefulService;
private static ConversationalClient conversationalStatefulClientStatelessService;
@@ -49,7 +49,7 @@ public class StatelessStatelessTestCase { @BeforeClass
public static void setUp() throws Exception {
try {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/main/resources/Conversational").toURL().toString()));
diff --git a/java/sca/itest/databindings/jaxb-top-down/pom.xml b/java/sca/itest/databindings/jaxb-top-down/pom.xml index aef3be7337..ae506499d4 100644 --- a/java/sca/itest/databindings/jaxb-top-down/pom.xml +++ b/java/sca/itest/databindings/jaxb-top-down/pom.xml @@ -62,7 +62,7 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> diff --git a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java index 01357aafb3..37a521b1bd 100644 --- a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java +++ b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java @@ -28,8 +28,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceClient; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; @@ -40,14 +40,14 @@ import org.junit.Test; public class DatabindingTestCase { private static SCAClient client; - private static SCANode2 node; + private static SCANode node; /** * Runs once before running the tests */ @BeforeClass public static void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/helloservice.composite", null); node.start(); client = (SCAClient)node; diff --git a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java index 41a8f3cadd..65b8a5abc3 100644 --- a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java +++ b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java @@ -23,8 +23,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesServiceClient; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; @@ -35,14 +35,14 @@ import org.junit.Test; public class PrimitivesDatabindingTestCase { private static SCAClient domain; - private static SCANode2 node; + private static SCANode node; /** * Runs before each test method */ @BeforeClass public static void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/primitivesservice.composite", null); node.start(); domain = (SCAClient)node; diff --git a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java index c177dbc935..dc49f0f407 100644 --- a/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java +++ b/java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java @@ -56,8 +56,8 @@ import org.apache.tuscany.sca.databinding.xml.String2Node; import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesServiceClient; import org.apache.tuscany.sca.itest.databindings.jaxb.impl.StandardTypesTransformer; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Ignore; @@ -70,14 +70,14 @@ import org.xml.sax.InputSource; public class StandardTypesDatabindingTestCase { private static SCAClient domain; - private static SCANode2 node; + private static SCANode node; /** * Runs once before the tests */ @BeforeClass public static void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/standard-types-service.composite", null); node.start(); domain = (SCAClient)node; diff --git a/java/sca/itest/domain/pom.xml b/java/sca/itest/domain/pom.xml index 964e723f9e..930bcda79d 100644 --- a/java/sca/itest/domain/pom.xml +++ b/java/sca/itest/domain/pom.xml @@ -32,13 +32,13 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-api</artifactId>
+ <artifactId>tuscany-node-api</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-launcher</artifactId>
+ <artifactId>tuscany-node-launcher</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
diff --git a/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java b/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java index 7761b0bf69..98f13df774 100644 --- a/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java +++ b/java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java @@ -50,8 +50,8 @@ import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.workspace.Workspace; import org.apache.tuscany.sca.workspace.WorkspaceFactory; import org.apache.tuscany.sca.workspace.builder.ContributionDependencyBuilder; @@ -219,9 +219,9 @@ public class ContributionSPIsTestCase { contributions[i] = new SCAContribution(contributionsToDeploy.get(i).getURI(), contributionsToDeploy.get(i).getLocation()); } - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); - SCANode2 node = nodeFactory.createSCANode(chosenDeployableLocation, contributions); + SCANode node = nodeFactory.createSCANode(chosenDeployableLocation, contributions); node.start(); SCAClient client = (SCAClient)node; diff --git a/java/sca/itest/late-reference-resolution/pom.xml b/java/sca/itest/late-reference-resolution/pom.xml index f73cc8a69b..f30931f309 100644 --- a/java/sca/itest/late-reference-resolution/pom.xml +++ b/java/sca/itest/late-reference-resolution/pom.xml @@ -39,13 +39,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java b/java/sca/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java index d3fe027e60..ebe834028d 100644 --- a/java/sca/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java +++ b/java/sca/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java @@ -25,8 +25,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.launcher.DomainManagerLauncher; import org.junit.AfterClass; import org.junit.BeforeClass; @@ -38,9 +38,9 @@ import org.junit.Test; */ public class LateReferenceResolutionTestCase { - private static SCANode2 nodeA; - private static SCANode2 nodeB; - private static SCANode2 nodeC; + private static SCANode nodeA; + private static SCANode nodeB; + private static SCANode nodeC; private static CalculatorService calculatorService; @@ -53,7 +53,7 @@ public class LateReferenceResolutionTestCase { System.out.println("Setting up domain"); - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); nodeC = nodeFactory.createSCANode(new File("src/main/resources/nodeC/Calculator.composite").toURL().toString(), new SCAContribution("NodeC", new File("src/main/resources/nodeC").toURL().toString())); diff --git a/java/sca/itest/oneway/pom.xml b/java/sca/itest/oneway/pom.xml index 9260b63dce..ba61e1e0c0 100644 --- a/java/sca/itest/oneway/pom.xml +++ b/java/sca/itest/oneway/pom.xml @@ -44,7 +44,7 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-impl</artifactId>
+ <artifactId>tuscany-node-impl</artifactId>
<version>1.4-SNAPSHOT</version>
<scope>runtime</scope>
</dependency>
diff --git a/java/sca/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java b/java/sca/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java index b21042c06b..c490150ec5 100644 --- a/java/sca/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java +++ b/java/sca/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java @@ -31,8 +31,8 @@ import org.apache.tuscany.sca.core.invocation.NonBlockingInterceptor; import org.apache.tuscany.sca.itest.oneway.impl.OneWayClientImpl;
import org.apache.tuscany.sca.itest.oneway.impl.OneWayServiceImpl;
import org.apache.tuscany.sca.node.SCAClient;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -49,7 +49,7 @@ public class OneWayTestCase { */
private static final int MAX_SLEEP_TIME = 10000;
- private SCANode2 node;
+ private SCANode node;
/**
* Initialise the SCADomain.
@@ -59,7 +59,7 @@ public class OneWayTestCase { @Before
public void setUp() throws Exception {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANodeFromClassLoader("OneWayContribution/META-INF/sca-deployables/oneWay.composite", null);
node.start();
diff --git a/java/sca/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml b/java/sca/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml index 017293ea73..ea1c78fa2a 100644 --- a/java/sca/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml +++ b/java/sca/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml @@ -487,17 +487,17 @@ </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>${pom.version}</version> </dependency> <dependency> <groupId>${pom.groupId}</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>${pom.version}</version> </dependency> <dependency> diff --git a/java/sca/itest/validation/pom.xml b/java/sca/itest/validation/pom.xml index 1bcad7bd90..3d1d0c04f5 100644 --- a/java/sca/itest/validation/pom.xml +++ b/java/sca/itest/validation/pom.xml @@ -44,7 +44,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java index 84c77ae297..555810f453 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ComponentReferenceTargetNotFoundTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ComponentReferenceTargetNotFound/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ComponentReferenceTargetNotFound").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java index 65dab38ee3..7593f39991 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java @@ -29,19 +29,19 @@ import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** * This shows how to test the Calculator service component. */ public class DuplicateImplementationPropertyNameTestCase extends TestCase { - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/DuplicateImplementationPropertyName/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/DuplicateImplementationPropertyName").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java index 6c10d1279c..0a711175dc 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java @@ -29,8 +29,8 @@ import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -38,11 +38,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; */ public class DuplicateImplementationReferenceNameTestCase extends TestCase { - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/DuplicateImplementationReferenceName/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/DuplicateImplementationReferenceName").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java index 4531564ccb..10660795a7 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class DuplicatePropertyNameTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/DuplicatePropertyName/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/DuplicatePropertyName").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java index 3b024c58c7..15b4b15989 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class DuplicateReferenceNameTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/DuplicateReferenceName/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/DuplicateReferenceName").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java index 4f54b023f4..55741ec2ef 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class MultipleBindingsForServiceTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/MultipleBindingsForService/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/MultipleBindingsForService").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java index 14af754860..7f8bd68e5e 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java @@ -29,8 +29,8 @@ import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -39,11 +39,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class NoComponentImplementationTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/NoComponentImplementation/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/NoComponentImplementation").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java index 2f2e87f9af..1f26d3a7d6 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class NoCompositeNamespaceTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/NoCompositeNamespace/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/NoCompositeNamespace").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java index 8deba283cb..d398efc9ea 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class NoMatchingBindingTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode("Calculator.composite", new SCAContribution("TestContribution", new File("src/main/resources/NoMatchingBinding") .toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java index 07c75decbc..9d2f028dea 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PromotedReferenceNotFoundTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PromotedReferenceNotFound/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PromotedReferenceNotFound").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java index 26c988c1c1..7f836e4b01 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PromotedServiceNotFoundTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PromotedServiceNotFound/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PromotedServiceNotFound").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java index 3753fc278c..04c2594cd3 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PropertyAttributeMustSupplyNullTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PropertyAttribute/CalculatorNullMustSupply.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PropertyAttribute").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java index 08e5a9861b..3dabfecbb6 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PropertyAttributeTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PropertyAttribute/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PropertyAttribute").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java index 4af2675c09..0dca8ed1df 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PropertyNotFoundTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PropertyNotFound/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PropertyNotFound").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java index 11fde0a73d..37f7ef352e 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class PropertyOverrideManyAttributeTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/PropertyAttribute/CalculatorOverrideManyAttribute.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/PropertyAttribute").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java index 19b04e6940..ab57283a9e 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ReferenceIncompatibleComponentInterfaceTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ReferenceIncompatibleComponentInterface/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ReferenceIncompatibleComponentInterface").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java index 3180539898..4c3cc3856a 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ReferenceIncompatibleInterfaceTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ReferenceIncompatibleInterface/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ReferenceIncompatibleInterface").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java index 87ae0f0e3c..06fb06f6ad 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ReferenceIncompatibleMultiplicityTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ReferenceIncompatibleMultiplicity/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ReferenceIncompatibleMultiplicity").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java index 4856ba507f..c958d2eb82 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ReferenceNotFoundTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ReferenceNotFound/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ReferenceNotFound").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java index f456ae40af..d615857105 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ReferenceWithoutTargetsTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ReferenceWithoutTargets/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ReferenceWithoutTargets").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java index 51adc22848..e9b920119a 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -40,11 +40,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class ServiceNotFoundForComponentServiceTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/ServiceNotFoundForComponentService/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/ServiceNotFoundForComponentService").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java index 918108c275..4d950e30ff 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java @@ -29,8 +29,8 @@ import org.apache.tuscany.sca.monitor.MonitorFactory; import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.logging.impl.DefaultLoggingMonitorImpl; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; /** @@ -39,11 +39,11 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; public class UnresolvedComponentImplementationTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANode(new File("src/main/resources/UnresolvedComponentImplementation/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/UnresolvedComponentImplementation").toURL().toString())); diff --git a/java/sca/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java b/java/sca/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java index 93edfa2e21..60b08764c1 100644 --- a/java/sca/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java +++ b/java/sca/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java @@ -24,8 +24,8 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * This shows how to test the Calculator service component. @@ -33,12 +33,12 @@ import org.apache.tuscany.sca.node.SCANode2Factory; public class XSDValidationTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; private Exception startUpException; @Override protected void setUp() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { node = nodeFactory.createSCANode(new File("src/main/resources/XsdValidation/Calculator.composite").toURL().toString(), new SCAContribution("TestContribution", diff --git a/java/sca/modules/domain-manager/pom.xml b/java/sca/modules/domain-manager/pom.xml index 56366fb177..ff197e8aeb 100644 --- a/java/sca/modules/domain-manager/pom.xml +++ b/java/sca/modules/domain-manager/pom.xml @@ -67,7 +67,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> @@ -79,7 +79,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> <scope>runtime</scope> </dependency> diff --git a/java/sca/modules/domain-manager/src/main/java/org/apache/tuscany/sca/domain/manager/launcher/DomainManagerLauncherBootstrap.java b/java/sca/modules/domain-manager/src/main/java/org/apache/tuscany/sca/domain/manager/launcher/DomainManagerLauncherBootstrap.java index 3e78073264..f96e19ed72 100644 --- a/java/sca/modules/domain-manager/src/main/java/org/apache/tuscany/sca/domain/manager/launcher/DomainManagerLauncherBootstrap.java +++ b/java/sca/modules/domain-manager/src/main/java/org/apache/tuscany/sca/domain/manager/launcher/DomainManagerLauncherBootstrap.java @@ -21,8 +21,8 @@ package org.apache.tuscany.sca.domain.manager.launcher; import org.apache.tuscany.sca.domain.manager.impl.DomainManagerConfiguration; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * Bootstrap class for the SCA domain manager. @@ -30,15 +30,15 @@ import org.apache.tuscany.sca.node.SCANode2Factory; * @version $Rev$ $Date$ */ public class DomainManagerLauncherBootstrap { - private SCANode2 node; + private SCANode node; /** * A node wrappering an instance of a domain manager. */ - public static class NodeFacade implements SCANode2 { + public static class NodeFacade implements SCANode { private ClassLoader threadContextClassLoader; private ClassLoader runtimeClassLoader; - private SCANode2 node; + private SCANode node; private String rootDirectory; private NodeFacade(String rootDirectory) { @@ -51,7 +51,7 @@ public class DomainManagerLauncherBootstrap { boolean started = false; try { Thread.currentThread().setContextClassLoader(runtimeClassLoader); - SCANode2Factory factory = SCANode2Factory.newInstance(); + SCANodeFactory factory = SCANodeFactory.newInstance(); node = factory.createSCANodeFromClassLoader("DomainManager.composite", getClass().getClassLoader()); node.start(); @@ -88,7 +88,7 @@ public class DomainManagerLauncherBootstrap { * Returns the node representing the domain manager. * @return */ - public SCANode2 getNode() { + public SCANode getNode() { return node; } diff --git a/java/sca/modules/host-embedded/pom.xml b/java/sca/modules/host-embedded/pom.xml index 4cb523b9a0..92fd8cc016 100644 --- a/java/sca/modules/host-embedded/pom.xml +++ b/java/sca/modules/host-embedded/pom.xml @@ -31,7 +31,7 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> diff --git a/java/sca/modules/host-embedded/src/main/java/org/apache/tuscany/sca/host/embedded/impl/DefaultSCADomain.java b/java/sca/modules/host-embedded/src/main/java/org/apache/tuscany/sca/host/embedded/impl/DefaultSCADomain.java index 8316759206..1bca290c27 100644 --- a/java/sca/modules/host-embedded/src/main/java/org/apache/tuscany/sca/host/embedded/impl/DefaultSCADomain.java +++ b/java/sca/modules/host-embedded/src/main/java/org/apache/tuscany/sca/host/embedded/impl/DefaultSCADomain.java @@ -43,8 +43,8 @@ import org.apache.tuscany.sca.host.embedded.management.ComponentListener; import org.apache.tuscany.sca.host.embedded.management.ComponentManager; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.apache.tuscany.sca.node.impl.NodeImpl; import org.osoa.sca.CallableReference; import org.osoa.sca.ServiceReference; @@ -68,7 +68,7 @@ public class DefaultSCADomain extends SCADomain { private List<String> contributionURLs; private CompositeActivator compositeActivator; - private SCANode2 node; + private SCANode node; private SCAClient client; /** @@ -149,7 +149,7 @@ public class DefaultSCADomain extends SCADomain { } public void init() { - SCANode2Factory factory = SCANode2Factory.newInstance(); + SCANodeFactory factory = SCANodeFactory.newInstance(); List<SCAContribution> contributions = new ArrayList<SCAContribution>(); diff --git a/java/sca/modules/implementation-node-runtime/pom.xml b/java/sca/modules/implementation-node-runtime/pom.xml index d043a1f909..c040b44d11 100644 --- a/java/sca/modules/implementation-node-runtime/pom.xml +++ b/java/sca/modules/implementation-node-runtime/pom.xml @@ -44,13 +44,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> @@ -68,7 +68,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> <scope>runtime</scope> </dependency> diff --git a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationDaemonBootstrap.java b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationDaemonBootstrap.java index edf2aefdde..7d5954b3fd 100644 --- a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationDaemonBootstrap.java +++ b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationDaemonBootstrap.java @@ -20,7 +20,7 @@ package org.apache.tuscany.sca.implementation.node.launcher; import org.apache.tuscany.sca.host.embedded.SCADomain; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; /** * Bootstrap class for the SCA node daemon. @@ -28,12 +28,12 @@ import org.apache.tuscany.sca.node.SCANode2; * @version $Rev$ $Date$ */ public class NodeImplementationDaemonBootstrap { - private SCANode2 node; + private SCANode node; /** * A node wrappering an instance of a node daemon. */ - public static class NodeFacade implements SCANode2 { + public static class NodeFacade implements SCANode { private ClassLoader threadContextClassLoader; private ClassLoader runtimeClassLoader; private SCADomain daemon; @@ -77,7 +77,7 @@ public class NodeImplementationDaemonBootstrap { * Returns the node representing the daemon. * @return */ - public SCANode2 getNode() { + public SCANode getNode() { return node; } diff --git a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationLauncherBootstrap.java b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationLauncherBootstrap.java index 06b1966c57..0264574fb9 100644 --- a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationLauncherBootstrap.java +++ b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/launcher/NodeImplementationLauncherBootstrap.java @@ -21,8 +21,8 @@ package org.apache.tuscany.sca.implementation.node.launcher; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.osoa.sca.CallableReference; import org.osoa.sca.ServiceReference; @@ -33,17 +33,17 @@ import org.osoa.sca.ServiceReference; */ public class NodeImplementationLauncherBootstrap { - private SCANode2 node; + private SCANode node; /** * A node facade. */ - public static class NodeFacade implements SCANode2, SCAClient { + public static class NodeFacade implements SCANode, SCAClient { private ClassLoader threadContextClassLoader; private ClassLoader runtimeClassLoader; - private SCANode2 delegate; + private SCANode delegate; - private NodeFacade(SCANode2 delegate) { + private NodeFacade(SCANode delegate) { runtimeClassLoader = Thread.currentThread().getContextClassLoader(); this.delegate = delegate; } @@ -90,7 +90,7 @@ public class NodeImplementationLauncherBootstrap { * @param configurationURI */ public NodeImplementationLauncherBootstrap(String configurationURI) throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = new NodeFacade(nodeFactory.createSCANodeFromURL(configurationURI)); } @@ -101,7 +101,7 @@ public class NodeImplementationLauncherBootstrap { * @param contributionClassLoader */ public NodeImplementationLauncherBootstrap(String compositeURI, ClassLoader contributionClassLoader) throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = new NodeFacade(nodeFactory.createSCANodeFromClassLoader(compositeURI, contributionClassLoader)); } @@ -113,7 +113,7 @@ public class NodeImplementationLauncherBootstrap { * @param locations */ public NodeImplementationLauncherBootstrap(String compositeURI, String[] uris, String[] locations) throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); SCAContribution[] contributions = new SCAContribution[uris.length]; for (int i = 0; i < uris.length; i++) { contributions[i] = new SCAContribution(uris[i], locations[i]); @@ -129,7 +129,7 @@ public class NodeImplementationLauncherBootstrap { * @param locations */ public NodeImplementationLauncherBootstrap(String compositeURI, String compositeContent, String[] uris, String[] locations) throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); SCAContribution[] contributions = new SCAContribution[uris.length]; for (int i = 0; i < uris.length; i++) { contributions[i] = new SCAContribution(uris[i], locations[i]); @@ -142,7 +142,7 @@ public class NodeImplementationLauncherBootstrap { * * @return */ - public SCANode2 getNode() { + public SCANode getNode() { return node; } diff --git a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/webapp/NodeWebAppServletHost.java b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/webapp/NodeWebAppServletHost.java index 47b42c9224..5a50f87d4c 100644 --- a/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/webapp/NodeWebAppServletHost.java +++ b/java/sca/modules/implementation-node-runtime/src/main/java/org/apache/tuscany/sca/implementation/node/webapp/NodeWebAppServletHost.java @@ -48,8 +48,8 @@ import org.apache.tuscany.sca.host.http.ServletHostExtensionPoint; import org.apache.tuscany.sca.host.http.ServletMappingException; import org.apache.tuscany.sca.implementation.node.launcher.NodeImplementationLauncherUtil; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * ServletHost implementation for use in a Webapp Node environment. @@ -62,7 +62,7 @@ public class NodeWebAppServletHost implements ServletHost, Filter { private static final NodeWebAppServletHost servletHost = new NodeWebAppServletHost(); private Map<String, Servlet> servlets = new HashMap<String, Servlet>(); - private SCANode2 node; + private SCANode node; private String contextPath = "/"; private int defaultPort = 8080; @@ -112,7 +112,7 @@ public class NodeWebAppServletHost implements ServletHost, Filter { String nodeConfiguration = NodeImplementationLauncherUtil.nodeConfigurationURI(nodeName); // Create the SCA node - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); node = nodeFactory.createSCANodeFromURL(nodeConfiguration); // Register the Servlet host @@ -350,7 +350,7 @@ public class NodeWebAppServletHost implements ServletHost, Filter { * * @return */ - private static ServletHostExtensionPoint servletHosts(SCANode2 node) { + private static ServletHostExtensionPoint servletHosts(SCANode node) { //FIXME Need a clean way to get the extension point registry // from the node ExtensionPointRegistry registry; diff --git a/java/sca/modules/node2-api/LICENSE b/java/sca/modules/node-api/LICENSE index 6e529a25c4..6e529a25c4 100644 --- a/java/sca/modules/node2-api/LICENSE +++ b/java/sca/modules/node-api/LICENSE diff --git a/java/sca/modules/node2-api/NOTICE b/java/sca/modules/node-api/NOTICE index 1325efd8bf..1325efd8bf 100644 --- a/java/sca/modules/node2-api/NOTICE +++ b/java/sca/modules/node-api/NOTICE diff --git a/java/sca/modules/node2-api/pom.xml b/java/sca/modules/node-api/pom.xml index 8e52a99014..1cc386f6bc 100644 --- a/java/sca/modules/node2-api/pom.xml +++ b/java/sca/modules/node-api/pom.xml @@ -27,7 +27,7 @@ <relativePath>../pom.xml</relativePath>
</parent>
- <artifactId>tuscany-node2-api</artifactId>
+ <artifactId>tuscany-node-api</artifactId>
<name>Apache Tuscany SCA Node API</name>
<dependencies>
diff --git a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCAClient.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCAClient.java index f390e8881e..f390e8881e 100644 --- a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCAClient.java +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCAClient.java diff --git a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCAContribution.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCAContribution.java index de7f352122..de7f352122 100644 --- a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCAContribution.java +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCAContribution.java diff --git a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCANode2.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode.java index c193467b09..fea749a57c 100644 --- a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCANode2.java +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode.java @@ -27,7 +27,7 @@ package org.apache.tuscany.sca.node; * * @version $Rev$ $Date$ */ -public interface SCANode2 { +public interface SCANode { /** * Start the composite loaded in the node. diff --git a/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode2.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode2.java new file mode 100644 index 0000000000..a1d4ddb2b1 --- /dev/null +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode2.java @@ -0,0 +1,33 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.tuscany.sca.node; + + + +/** + * Represents an SCA processing node. + * A node is loaded with an SCA composites. It can start and stop that composite. + * + * @version $Rev$ $Date$ + * @deprecated Use SCANode instead + */ +@Deprecated +public interface SCANode2 extends SCANode { +} diff --git a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCANode2Factory.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode2Factory.java index 9b63531a94..2b0dbc88eb 100644 --- a/java/sca/modules/node2-api/src/main/java/org/apache/tuscany/sca/node/SCANode2Factory.java +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANode2Factory.java @@ -30,7 +30,9 @@ import org.osoa.sca.ServiceRuntimeException; * with an SCA composite and the SCA contributions required by the composite. * * @version $Rev$ $Date$ + * @deprecated Use SCANodeFactory */ +@Deprecated public abstract class SCANode2Factory { public static class NodeProxy implements SCANode2, SCAClient { @@ -138,7 +140,7 @@ public abstract class SCANode2Factory { } // Fail back to default impl - String className = "org.apache.tuscany.sca.node.impl.NodeFactoryImpl"; + String className = "org.apache.tuscany.sca.node.impl.Node2FactoryImpl"; Class<?> cls = Class.forName(className, true, classLoader); scaNodeFactory = (SCANode2Factory)cls.newInstance(); diff --git a/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANodeFactory.java b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANodeFactory.java new file mode 100644 index 0000000000..6d02d654e2 --- /dev/null +++ b/java/sca/modules/node-api/src/main/java/org/apache/tuscany/sca/node/SCANodeFactory.java @@ -0,0 +1,201 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.tuscany.sca.node; + +import java.lang.reflect.InvocationTargetException; + +import org.osoa.sca.CallableReference; +import org.osoa.sca.ServiceReference; +import org.osoa.sca.ServiceRuntimeException; + +/** + * A factory for SCA processing nodes. An SCA processing node can be loaded + * with an SCA composite and the SCA contributions required by the composite. + * + * @version $Rev$ $Date$ + */ +public abstract class SCANodeFactory { + + public static class NodeProxy implements SCANode, SCAClient { + private Object node; + + private NodeProxy(Object node) { + super(); + this.node = node; + } + + public static <T> T createProxy(Class<T> type, Object node) { + try { + return type.getDeclaredConstructor(Object.class).newInstance(node); + } catch (Exception e) { + throw new IllegalArgumentException(e); + } + } + + public <B, R extends CallableReference<B>> R cast(B target) throws IllegalArgumentException { + try { + return (R)node.getClass().getMethod("cast", Object.class).invoke(node, target); + } catch (Throwable e) { + handleException(e); + return null; + } + } + + public <B> B getService(Class<B> businessInterface, String serviceName) { + try { + return (B)node.getClass().getMethod("getService", Class.class, String.class).invoke(node, + businessInterface, + serviceName); + } catch (Throwable e) { + handleException(e); + return null; + } + } + + public <B> ServiceReference<B> getServiceReference(Class<B> businessInterface, String serviceName) { + try { + return (ServiceReference<B>)node.getClass().getMethod("getServiceReference", Class.class, String.class) + .invoke(node, businessInterface, serviceName); + } catch (Throwable e) { + handleException(e); + return null; + } + } + + public void start() { + try { + node.getClass().getMethod("start").invoke(node); + } catch (Throwable e) { + handleException(e); + } + } + + public void stop() { + try { + node.getClass().getMethod("stop").invoke(node); + } catch (Throwable e) { + handleException(e); + } + } + + private static void handleException(Throwable ex) { + if (ex instanceof InvocationTargetException) { + ex = ((InvocationTargetException)ex).getTargetException(); + } + if (ex instanceof RuntimeException) { + throw (RuntimeException)ex; + } + if (ex instanceof Error) { + throw (Error)ex; + } else { + throw new RuntimeException(ex); + } + } + + } + + /** + * Returns a new SCA node factory instance. + * + * @return a new SCA node factory + */ + public static SCANodeFactory newInstance() { + SCANodeFactory scaNodeFactory = null; + + try { + final ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); + // Use reflection APIs to call ServiceDiscovery to avoid hard dependency to tuscany-extensibility + try { + Class<?> discoveryClass = + Class.forName("org.apache.tuscany.sca.extensibility.ServiceDiscovery", true, classLoader); + Object instance = discoveryClass.getMethod("getInstance").invoke(null); + Class<?> factoryImplClass = + (Class<?>)discoveryClass.getMethod("loadFirstServiceClass", Class.class) + .invoke(instance, SCANodeFactory.class); + if (factoryImplClass != null) { + scaNodeFactory = (SCANodeFactory)factoryImplClass.newInstance(); + return scaNodeFactory; + } + } catch (ClassNotFoundException e) { + // Ignore + } + + // Fail back to default impl + String className = "org.apache.tuscany.sca.node.impl.NodeFactoryImpl"; + + Class<?> cls = Class.forName(className, true, classLoader); + scaNodeFactory = (SCANodeFactory)cls.newInstance(); + return scaNodeFactory; + + } catch (Exception e) { + throw new ServiceRuntimeException(e); + } + } + + /** + * Create a SCA node based on the discovery of the contribution on the classpath for the + * given classloader. This method should be treated a convinient shortcut with the following + * assumptions: + * <ul> + * <li>This is a standalone application and there is a deployable composite file on the classpath. + * <li>There is only one contribution which contains the deployable composite file physically in its packaging hierarchy. + * </ul> + * @param compositeURI The URI of the composite file relative to the root of the enclosing contribution + * @param classLoader The ClassLoader used to load the composite file as a resource. If the value is null, + * then thread context classloader will be used + * @return A newly created SCA node + */ + public abstract SCANode createSCANodeFromClassLoader(String compositeURI, ClassLoader classLoader); + + /** + * Creates a new SCA node from the configuration URL + * + * @param configurationURL the URL of the node configuration which is the ATOM feed + * that contains the URI of the composite and a collection of URLs for the contributions + * + * @return a new SCA node. + */ + public abstract SCANode createSCANodeFromURL(String configurationURL); + + /** + * Creates a new SCA node. + * + * @param compositeURI the URI of the composite to use + * @param contributions the URI of the contributions that provides the composites and related + * artifacts. If the list is empty, then we will use the thread context classloader to discover + * the contribution on the classpath + * + * @return a new SCA node. + */ + public abstract SCANode createSCANode(String compositeURI, SCAContribution... contributions); + + /** + * Creates a new SCA node. + * + * @param compositeURI the URI of the composite to use + * @param compositeContent the XML content of the composite to use + * @param contributions the URI of the contributions that provides the composites and related artifacts + * @return a new SCA node. + */ + public abstract SCANode createSCANode(String compositeURI, + String compositeContent, + SCAContribution... contributions); + +} diff --git a/java/sca/modules/node2-impl/LICENSE b/java/sca/modules/node-impl/LICENSE index 8aa906c321..8aa906c321 100644 --- a/java/sca/modules/node2-impl/LICENSE +++ b/java/sca/modules/node-impl/LICENSE diff --git a/java/sca/modules/node2-impl/NOTICE b/java/sca/modules/node-impl/NOTICE index fdfa0e9faa..fdfa0e9faa 100644 --- a/java/sca/modules/node2-impl/NOTICE +++ b/java/sca/modules/node-impl/NOTICE diff --git a/java/sca/modules/node2-impl/pom.xml b/java/sca/modules/node-impl/pom.xml index 4f6f73d9be..7bad8a5750 100644 --- a/java/sca/modules/node2-impl/pom.xml +++ b/java/sca/modules/node-impl/pom.xml @@ -27,7 +27,7 @@ <relativePath>../pom.xml</relativePath> </parent> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <name>Apache Tuscany SCA Node Implementation</name> <dependencies> @@ -46,7 +46,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/modules/node2-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/Node2FactoryImpl.java index 3ec0958e4f..419900c5ac 100644 --- a/java/sca/modules/node2-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/Node2FactoryImpl.java @@ -27,29 +27,31 @@ import org.apache.tuscany.sca.node.SCANode2Factory; * Default implementation of an SCA node factory. * * @version $Rev$ $Date$ + * @deprecated */ -public class NodeFactoryImpl extends SCANode2Factory { - public NodeFactoryImpl() { +@Deprecated +public class Node2FactoryImpl extends SCANode2Factory { + public Node2FactoryImpl() { } @Override public SCANode2 createSCANodeFromClassLoader(String compositeURI, ClassLoader classLoader) { - return new NodeImpl(classLoader, compositeURI); + return new Node2Impl(classLoader, compositeURI); } @Override public SCANode2 createSCANodeFromURL(String configurationURI) { - return new NodeImpl(configurationURI); + return new Node2Impl(configurationURI); } @Override public SCANode2 createSCANode(String compositeURI, SCAContribution... contributions) { - return new NodeImpl(compositeURI, contributions); + return new Node2Impl(compositeURI, contributions); } @Override public SCANode2 createSCANode(String compositeURI, String compositeContent, SCAContribution... contributions) { - return new NodeImpl(compositeURI, compositeContent, contributions); + return new Node2Impl(compositeURI, compositeContent, contributions); } } diff --git a/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/Node2Impl.java b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/Node2Impl.java new file mode 100644 index 0000000000..bc2f10fb7e --- /dev/null +++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/Node2Impl.java @@ -0,0 +1,63 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.tuscany.sca.node.impl; + +import org.apache.tuscany.sca.node.SCAContribution; +import org.apache.tuscany.sca.node.SCANode2; + +/** + * Node2 Impl + */ +public class Node2Impl extends NodeImpl implements SCANode2 { + + /** + * @param configurationURI + */ + public Node2Impl(String configurationURI) { + super(configurationURI); + // TODO Auto-generated constructor stub + } + + /** + * @param classLoader + * @param compositeURI + */ + public Node2Impl(ClassLoader classLoader, String compositeURI) { + super(classLoader, compositeURI); + } + + /** + * @param compositeURI + * @param contributions + */ + public Node2Impl(String compositeURI, SCAContribution[] contributions) { + super(compositeURI, contributions); + } + + /** + * @param compositeURI + * @param compositeContent + * @param contributions + */ + public Node2Impl(String compositeURI, String compositeContent, SCAContribution[] contributions) { + super(compositeURI, compositeContent, contributions); + } + +} 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 new file mode 100644 index 0000000000..18b166acdd --- /dev/null +++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeFactoryImpl.java @@ -0,0 +1,55 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.tuscany.sca.node.impl; + +import org.apache.tuscany.sca.node.SCAContribution; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; + +/** + * Default implementation of an SCA node factory. + * + * @version $Rev$ $Date$ + */ +public class NodeFactoryImpl extends SCANodeFactory { + public NodeFactoryImpl() { + } + + @Override + public SCANode createSCANodeFromClassLoader(String compositeURI, ClassLoader classLoader) { + return new NodeImpl(classLoader, compositeURI); + } + + @Override + public SCANode createSCANodeFromURL(String configurationURI) { + return new NodeImpl(configurationURI); + } + + @Override + public SCANode createSCANode(String compositeURI, SCAContribution... contributions) { + return new NodeImpl(compositeURI, contributions); + } + + @Override + public SCANode createSCANode(String compositeURI, String compositeContent, SCAContribution... contributions) { + return new NodeImpl(compositeURI, compositeContent, contributions); + } + +} diff --git a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java index 835829db1a..e35203bc5b 100644 --- a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java +++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/NodeImpl.java @@ -71,7 +71,7 @@ import org.apache.tuscany.sca.monitor.Problem; import org.apache.tuscany.sca.monitor.Problem.Severity; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.runtime.RuntimeComponent; import org.apache.tuscany.sca.runtime.RuntimeComponentContext; import org.osoa.sca.CallableReference; @@ -83,7 +83,7 @@ import org.osoa.sca.ServiceRuntimeException; * * @version $Rev$ $Date$ */ -public class NodeImpl implements SCANode2, SCAClient { +public class NodeImpl implements SCANode, SCAClient { private static final Logger logger = Logger.getLogger(NodeImpl.class.getName()); @@ -144,6 +144,11 @@ public class NodeImpl implements SCANode2, SCAClient { } } + /** + * Construct a node by discovering the node configuration (composite+contrbutions) on the classpath + * @param classLoader + * @param compositeURI + */ NodeImpl(ClassLoader classLoader, String compositeURI) { configurationName = compositeURI; logger.log(Level.INFO, "Creating node: " + configurationName); diff --git a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBootStrapper.java b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBootStrapper.java index c9995d6024..c9995d6024 100644 --- a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBootStrapper.java +++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBootStrapper.java diff --git a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBuilder.java b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBuilder.java index 98a44cef9e..98a44cef9e 100644 --- a/java/sca/modules/node2-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBuilder.java +++ b/java/sca/modules/node-impl/src/main/java/org/apache/tuscany/sca/node/impl/RuntimeBuilder.java diff --git a/java/sca/modules/node-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANode2Factory b/java/sca/modules/node-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANode2Factory new file mode 100644 index 0000000000..4215855ac9 --- /dev/null +++ b/java/sca/modules/node-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANode2Factory @@ -0,0 +1,17 @@ +# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+org.apache.tuscany.sca.node.impl.Node2FactoryImpl
\ No newline at end of file diff --git a/java/sca/modules/node2-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANode2Factory b/java/sca/modules/node-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANodeFactory index 800bdd84cc..800bdd84cc 100644 --- a/java/sca/modules/node2-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANode2Factory +++ b/java/sca/modules/node-impl/src/main/resources/META-INF/services/org.apache.tuscany.sca.node.SCANodeFactory diff --git a/java/sca/modules/node2-impl/src/test/java/hello/HelloWorld.java b/java/sca/modules/node-impl/src/test/java/hello/HelloWorld.java index 2f519cb81d..2f519cb81d 100644 --- a/java/sca/modules/node2-impl/src/test/java/hello/HelloWorld.java +++ b/java/sca/modules/node-impl/src/test/java/hello/HelloWorld.java diff --git a/java/sca/modules/node2-impl/src/test/java/hello/HelloWorldImpl.java b/java/sca/modules/node-impl/src/test/java/hello/HelloWorldImpl.java index c9a7560b12..c9a7560b12 100644 --- a/java/sca/modules/node2-impl/src/test/java/hello/HelloWorldImpl.java +++ b/java/sca/modules/node-impl/src/test/java/hello/HelloWorldImpl.java diff --git a/java/sca/modules/node2-impl/src/test/java/org/apache/tuscany/sca/node/impl/NodeImplTestCase.java b/java/sca/modules/node-impl/src/test/java/org/apache/tuscany/sca/node/impl/Node2ImplTestCase.java index 38fe211e7d..52d96dd72d 100644 --- a/java/sca/modules/node2-impl/src/test/java/org/apache/tuscany/sca/node/impl/NodeImplTestCase.java +++ b/java/sca/modules/node-impl/src/test/java/org/apache/tuscany/sca/node/impl/Node2ImplTestCase.java @@ -32,9 +32,9 @@ import org.apache.tuscany.sca.node.SCANode2Factory; import org.junit.Test; /** - * + * Test case for Node2Impl */ -public class NodeImplTestCase { +public class Node2ImplTestCase { private static String composite = "<composite xmlns=\"http://www.osoa.org/xmlns/sca/1.0\"" + " xmlns:tuscany=\"http://tuscany.apache.org/xmlns/sca/1.0\"" + " targetNamespace=\"http://sample/composite\"" @@ -47,7 +47,7 @@ public class NodeImplTestCase { @Test public void testNodeWithCompositeContent() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); SCANode2 node = factory.createSCANode("HelloWorld.composite", composite, contribution); testNode(node); @@ -55,14 +55,14 @@ public class NodeImplTestCase { @Test public void testNodeWithCompositeContentAndNoContribution() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCANode2 node = factory.createSCANode("HelloWorld.composite", composite); testNode(node); } @Test public void testNodeWithoutCompositeURI() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); SCANode2 node = factory.createSCANode(null, contribution); testNode(node); @@ -70,7 +70,7 @@ public class NodeImplTestCase { @Test public void testNodeWithCompositeURI() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); String compositeURI = new File("target/test-classes/HelloWorld.composite").toURI().toString(); SCANode2 node = factory.createSCANode(compositeURI, contribution); @@ -79,7 +79,7 @@ public class NodeImplTestCase { @Test public void testNodeWithRelativeCompositeURI() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); String compositeURI = "HelloWorld.composite"; SCANode2 node = factory.createSCANode(compositeURI, contribution); @@ -88,7 +88,7 @@ public class NodeImplTestCase { @Test public void testNodeWithRelativeCompositeURIAndNoContribution() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); String compositeURI = "HelloWorld.composite"; SCANode2 node = factory.createSCANode(compositeURI, new SCAContribution[0]); testNode(node); @@ -96,7 +96,7 @@ public class NodeImplTestCase { @Test public void testNodeWithClassLoader() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); String compositeURI = "HelloWorld.composite"; SCANode2 node = factory.createSCANodeFromClassLoader(compositeURI, HelloWorld.class.getClassLoader()); testNode(node); @@ -104,7 +104,7 @@ public class NodeImplTestCase { @Test public void testNodeWithClassLoaderAndNullComposite() { - SCANode2Factory factory = new NodeFactoryImpl(); + SCANode2Factory factory = SCANode2Factory.newInstance(); SCANode2 node = factory.createSCANodeFromClassLoader(null, HelloWorld.class.getClassLoader()); testNode(node); } diff --git a/java/sca/modules/node-impl/src/test/java/org/apache/tuscany/sca/node/impl/NodeImplTestCase.java b/java/sca/modules/node-impl/src/test/java/org/apache/tuscany/sca/node/impl/NodeImplTestCase.java new file mode 100644 index 0000000000..d620f6b62a --- /dev/null +++ b/java/sca/modules/node-impl/src/test/java/org/apache/tuscany/sca/node/impl/NodeImplTestCase.java @@ -0,0 +1,119 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * \"License\"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.tuscany.sca.node.impl; + +import hello.HelloWorld; + +import java.io.File; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.node.SCAClient; +import org.apache.tuscany.sca.node.SCAContribution; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; +import org.junit.Test; + +/** + * Test case for NodeImpl + */ +public class NodeImplTestCase { + private static String composite = + "<composite xmlns=\"http://www.osoa.org/xmlns/sca/1.0\"" + " xmlns:tuscany=\"http://tuscany.apache.org/xmlns/sca/1.0\"" + + " targetNamespace=\"http://sample/composite\"" + + " xmlns:sc=\"http://sample/composite\"" + + " name=\"HelloWorld\">" + + " <component name=\"HelloWorld\">" + + " <implementation.java class=\"hello.HelloWorldImpl\"/>" + + " </component>" + + " </composite>"; + + @Test + public void testNodeWithCompositeContent() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); + SCANode node = factory.createSCANode("HelloWorld.composite", composite, contribution); + testNode(node); + } + + @Test + public void testNodeWithCompositeContentAndNoContribution() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCANode node = factory.createSCANode("HelloWorld.composite", composite); + testNode(node); + } + + @Test + public void testNodeWithoutCompositeURI() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); + SCANode node = factory.createSCANode(null, contribution); + testNode(node); + } + + @Test + public void testNodeWithCompositeURI() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); + String compositeURI = new File("target/test-classes/HelloWorld.composite").toURI().toString(); + SCANode node = factory.createSCANode(compositeURI, contribution); + testNode(node); + } + + @Test + public void testNodeWithRelativeCompositeURI() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCAContribution contribution = new SCAContribution("c1", new File("target/test-classes").toURI().toString()); + String compositeURI = "HelloWorld.composite"; + SCANode node = factory.createSCANode(compositeURI, contribution); + testNode(node); + } + + @Test + public void testNodeWithRelativeCompositeURIAndNoContribution() { + SCANodeFactory factory = new NodeFactoryImpl(); + String compositeURI = "HelloWorld.composite"; + SCANode node = factory.createSCANode(compositeURI, new SCAContribution[0]); + testNode(node); + } + + @Test + public void testNodeWithClassLoader() { + SCANodeFactory factory = new NodeFactoryImpl(); + String compositeURI = "HelloWorld.composite"; + SCANode node = factory.createSCANodeFromClassLoader(compositeURI, HelloWorld.class.getClassLoader()); + testNode(node); + } + + @Test + public void testNodeWithClassLoaderAndNullComposite() { + SCANodeFactory factory = new NodeFactoryImpl(); + SCANode node = factory.createSCANodeFromClassLoader(null, HelloWorld.class.getClassLoader()); + testNode(node); + } + + private void testNode(SCANode node) { + node.start(); + HelloWorld hw = ((SCAClient)node).getService(HelloWorld.class, "HelloWorld"); + Assert.assertEquals("Hello, Node", hw.hello("Node")); + node.stop(); + } + +} diff --git a/java/sca/modules/node2-impl/src/test/resources/HelloWorld.composite b/java/sca/modules/node-impl/src/test/resources/HelloWorld.composite index 9e3299d691..9e3299d691 100644 --- a/java/sca/modules/node2-impl/src/test/resources/HelloWorld.composite +++ b/java/sca/modules/node-impl/src/test/resources/HelloWorld.composite diff --git a/java/sca/modules/node2-impl/src/test/resources/META-INF/sca-contribution.xml b/java/sca/modules/node-impl/src/test/resources/META-INF/sca-contribution.xml index 1d37bcebe0..1d37bcebe0 100644 --- a/java/sca/modules/node2-impl/src/test/resources/META-INF/sca-contribution.xml +++ b/java/sca/modules/node-impl/src/test/resources/META-INF/sca-contribution.xml diff --git a/java/sca/modules/node2-launcher-osgi/LICENSE b/java/sca/modules/node-launcher-osgi/LICENSE index 6e529a25c4..6e529a25c4 100644 --- a/java/sca/modules/node2-launcher-osgi/LICENSE +++ b/java/sca/modules/node-launcher-osgi/LICENSE diff --git a/java/sca/modules/node2-launcher-osgi/NOTICE b/java/sca/modules/node-launcher-osgi/NOTICE index 1325efd8bf..1325efd8bf 100644 --- a/java/sca/modules/node2-launcher-osgi/NOTICE +++ b/java/sca/modules/node-launcher-osgi/NOTICE diff --git a/java/sca/modules/node2-launcher-osgi/pom.xml b/java/sca/modules/node-launcher-osgi/pom.xml index 3565aaf31a..682a1725df 100644 --- a/java/sca/modules/node2-launcher-osgi/pom.xml +++ b/java/sca/modules/node-launcher-osgi/pom.xml @@ -27,7 +27,7 @@ <relativePath>../pom.xml</relativePath> </parent> - <artifactId>tuscany-node2-launcher-osgi</artifactId> + <artifactId>tuscany-node-launcher-osgi</artifactId> <name>Apache Tuscany SCA Node OSGi Launcher</name> <dependencies> diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/Contribution.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/Contribution.java index 0214d5185f..0214d5185f 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/Contribution.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/Contribution.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/DomainManagerLauncher.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/DomainManagerLauncher.java index 6c28ef8b28..6c28ef8b28 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/DomainManagerLauncher.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/DomainManagerLauncher.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHost.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHost.java index 0c54c89c40..0c54c89c40 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHost.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHost.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/JarFileFinder.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/JarFileFinder.java index 38c7093a16..38c7093a16 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/JarFileFinder.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/JarFileFinder.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherBundleActivator.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherBundleActivator.java index 13af11238e..13af11238e 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherBundleActivator.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherBundleActivator.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherException.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherException.java index bf17222e34..bf17222e34 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherException.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/LauncherException.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeDaemonLauncher.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeDaemonLauncher.java index f0e4e9da70..f0e4e9da70 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeDaemonLauncher.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeDaemonLauncher.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncher.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncher.java index 917838d521..917838d521 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncher.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncher.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherUtil.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherUtil.java index 6aafbd91bf..4a13c0a589 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherUtil.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherUtil.java @@ -102,7 +102,7 @@ final class NodeLauncherUtil { Object node = bootstrapClass.getMethod("getNode").invoke(bootstrap); try { - Class<?> type = Class.forName("org.apache.tuscany.sca.node.SCANode2Factory"); + Class<?> type = Class.forName("org.apache.tuscany.sca.node.SCANodeFactory"); type = type.getDeclaredClasses()[0]; return type.getMethod("createProxy", Class.class, Object.class).invoke(null, type, node); } catch (ClassNotFoundException e) { diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeMain.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeMain.java index 445ea80786..445ea80786 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeMain.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeMain.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeServletFilter.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeServletFilter.java index fcbe259dba..fcbe259dba 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeServletFilter.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/NodeServletFilter.java diff --git a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/OSGiHost.java b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/OSGiHost.java index c5ea0439de..c5ea0439de 100644 --- a/java/sca/modules/node2-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/OSGiHost.java +++ b/java/sca/modules/node-launcher-osgi/src/main/java/org/apache/tuscany/sca/node/osgi/launcher/OSGiHost.java diff --git a/java/sca/modules/node2-launcher-osgi/src/test/java/hello/HelloWorld.java b/java/sca/modules/node-launcher-osgi/src/test/java/hello/HelloWorld.java index 2f519cb81d..2f519cb81d 100644 --- a/java/sca/modules/node2-launcher-osgi/src/test/java/hello/HelloWorld.java +++ b/java/sca/modules/node-launcher-osgi/src/test/java/hello/HelloWorld.java diff --git a/java/sca/modules/node2-launcher-osgi/src/test/java/hello/HelloWorldImpl.java b/java/sca/modules/node-launcher-osgi/src/test/java/hello/HelloWorldImpl.java index c9a7560b12..c9a7560b12 100644 --- a/java/sca/modules/node2-launcher-osgi/src/test/java/hello/HelloWorldImpl.java +++ b/java/sca/modules/node-launcher-osgi/src/test/java/hello/HelloWorldImpl.java diff --git a/java/sca/modules/node2-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHostTestCase.java b/java/sca/modules/node-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHostTestCase.java index e5194d0e5f..e5194d0e5f 100644 --- a/java/sca/modules/node2-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHostTestCase.java +++ b/java/sca/modules/node-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/FelixOSGiHostTestCase.java diff --git a/java/sca/modules/node2-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherTestCase.java b/java/sca/modules/node-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherTestCase.java index 4c8a7c4719..97976e256a 100644 --- a/java/sca/modules/node2-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherTestCase.java +++ b/java/sca/modules/node-launcher-osgi/src/test/java/org/apache/tuscany/sca/node/osgi/launcher/NodeLauncherTestCase.java @@ -22,7 +22,7 @@ package org.apache.tuscany.sca.node.osgi.launcher; import hello.HelloWorld; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Ignore; @@ -51,7 +51,7 @@ public class NodeLauncherTestCase { @Test public void testLaunch() throws Exception { NodeLauncher launcher = NodeLauncher.newInstance(); - SCANode2 node = launcher.createNodeFromClassLoader("HelloWorld.composite", getClass().getClassLoader()); + SCANode node = launcher.createNodeFromClassLoader("HelloWorld.composite", getClass().getClassLoader()); node.start(); HelloWorld hw = ((SCAClient)node).getService(HelloWorld.class, "HelloWorld"); diff --git a/java/sca/modules/node2-launcher-osgi/src/test/resources/HelloWorld.composite b/java/sca/modules/node-launcher-osgi/src/test/resources/HelloWorld.composite index 9e3299d691..9e3299d691 100644 --- a/java/sca/modules/node2-launcher-osgi/src/test/resources/HelloWorld.composite +++ b/java/sca/modules/node-launcher-osgi/src/test/resources/HelloWorld.composite diff --git a/java/sca/modules/node2-launcher-webapp/LICENSE b/java/sca/modules/node-launcher-webapp/LICENSE index 6e529a25c4..6e529a25c4 100644 --- a/java/sca/modules/node2-launcher-webapp/LICENSE +++ b/java/sca/modules/node-launcher-webapp/LICENSE diff --git a/java/sca/modules/node2-launcher-webapp/NOTICE b/java/sca/modules/node-launcher-webapp/NOTICE index 1325efd8bf..1325efd8bf 100644 --- a/java/sca/modules/node2-launcher-webapp/NOTICE +++ b/java/sca/modules/node-launcher-webapp/NOTICE diff --git a/java/sca/modules/node2-launcher-webapp/pom.xml b/java/sca/modules/node-launcher-webapp/pom.xml index 5e09e9c58d..de5c843c17 100644 --- a/java/sca/modules/node2-launcher-webapp/pom.xml +++ b/java/sca/modules/node-launcher-webapp/pom.xml @@ -27,14 +27,14 @@ <relativePath>../pom.xml</relativePath> </parent> - <artifactId>tuscany-node2-launcher-webapp</artifactId> + <artifactId>tuscany-node-launcher-webapp</artifactId> <packaging>war</packaging> <name>Apache Tuscany SCA Node WebApp</name> <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> <scope>runtime</scope> </dependency> diff --git a/java/sca/modules/node2-launcher-webapp/src/main/webapp/META-INF/sca-contribution.xml b/java/sca/modules/node-launcher-webapp/src/main/webapp/META-INF/sca-contribution.xml index 78bbebbb83..78bbebbb83 100644 --- a/java/sca/modules/node2-launcher-webapp/src/main/webapp/META-INF/sca-contribution.xml +++ b/java/sca/modules/node-launcher-webapp/src/main/webapp/META-INF/sca-contribution.xml diff --git a/java/sca/modules/node2-launcher-webapp/src/main/webapp/WEB-INF/web.xml b/java/sca/modules/node-launcher-webapp/src/main/webapp/WEB-INF/web.xml index 6c2c943c99..6c2c943c99 100644 --- a/java/sca/modules/node2-launcher-webapp/src/main/webapp/WEB-INF/web.xml +++ b/java/sca/modules/node-launcher-webapp/src/main/webapp/WEB-INF/web.xml diff --git a/java/sca/modules/node2-launcher-webapp/src/main/webapp/index.jsp b/java/sca/modules/node-launcher-webapp/src/main/webapp/index.jsp index 3cc6c7b504..3cc6c7b504 100644 --- a/java/sca/modules/node2-launcher-webapp/src/main/webapp/index.jsp +++ b/java/sca/modules/node-launcher-webapp/src/main/webapp/index.jsp diff --git a/java/sca/modules/node2-launcher/LICENSE b/java/sca/modules/node-launcher/LICENSE index 6e529a25c4..6e529a25c4 100644 --- a/java/sca/modules/node2-launcher/LICENSE +++ b/java/sca/modules/node-launcher/LICENSE diff --git a/java/sca/modules/node2-launcher/NOTICE b/java/sca/modules/node-launcher/NOTICE index 1325efd8bf..1325efd8bf 100644 --- a/java/sca/modules/node2-launcher/NOTICE +++ b/java/sca/modules/node-launcher/NOTICE diff --git a/java/sca/modules/node2-launcher/pom.xml b/java/sca/modules/node-launcher/pom.xml index 6833e13c4f..4277f5109e 100644 --- a/java/sca/modules/node2-launcher/pom.xml +++ b/java/sca/modules/node-launcher/pom.xml @@ -27,7 +27,7 @@ <relativePath>../pom.xml</relativePath> </parent> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <name>Apache Tuscany SCA Node Launcher</name> <dependencies> diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/Contribution.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/Contribution.java index 4f4f861e2f..4f4f861e2f 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/Contribution.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/Contribution.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/DomainManagerLauncher.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/DomainManagerLauncher.java index f0c0a0a2f4..f0c0a0a2f4 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/DomainManagerLauncher.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/DomainManagerLauncher.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/LauncherException.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/LauncherException.java index 39e8d81139..39e8d81139 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/LauncherException.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/LauncherException.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeDaemonLauncher.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeDaemonLauncher.java index 2756bf2073..2756bf2073 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeDaemonLauncher.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeDaemonLauncher.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncher.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncher.java index 44a5430976..44a5430976 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncher.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncher.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncherUtil.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncherUtil.java index 6d8bcbe65c..6d8bcbe65c 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncherUtil.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeLauncherUtil.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeMain.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeMain.java index eafe4ddaa0..eafe4ddaa0 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeMain.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeMain.java diff --git a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeServletFilter.java b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeServletFilter.java index ad4009a1e1..ad4009a1e1 100644 --- a/java/sca/modules/node2-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeServletFilter.java +++ b/java/sca/modules/node-launcher/src/main/java/org/apache/tuscany/sca/node/launcher/NodeServletFilter.java diff --git a/java/sca/modules/node-manager/pom.xml b/java/sca/modules/node-manager/pom.xml index f39c818a7e..08152a6344 100644 --- a/java/sca/modules/node-manager/pom.xml +++ b/java/sca/modules/node-manager/pom.xml @@ -44,13 +44,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> @@ -81,7 +81,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> <scope>runtime</scope> </dependency> diff --git a/java/sca/modules/pom.xml b/java/sca/modules/pom.xml index aed561953b..7628b7c7ea 100644 --- a/java/sca/modules/pom.xml +++ b/java/sca/modules/pom.xml @@ -151,11 +151,11 @@ <module>implementation-xquery</module> <module>monitor</module> <module>monitor-logging</module> - <module>node2-api</module> - <module>node2-impl</module> - <module>node2-launcher</module> - <module>node2-launcher-osgi</module> - <module>node2-launcher-webapp</module> + <module>node-api</module> + <module>node-impl</module> + <module>node-launcher</module> + <module>node-launcher-osgi</module> + <module>node-launcher-webapp</module> <module>node-manager</module> <module>osgi-runtime</module> <module>policy</module> diff --git a/java/sca/modules/runtime/pom.xml b/java/sca/modules/runtime/pom.xml index b1f427b8f4..cde7c627b8 100644 --- a/java/sca/modules/runtime/pom.xml +++ b/java/sca/modules/runtime/pom.xml @@ -198,13 +198,13 @@ </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/samples/calculator-distributed/pom.xml b/java/sca/samples/calculator-distributed/pom.xml index 2ca8407957..a0f04d4a1a 100644 --- a/java/sca/samples/calculator-distributed/pom.xml +++ b/java/sca/samples/calculator-distributed/pom.xml @@ -39,13 +39,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/samples/calculator-distributed/src/main/java/node/LaunchCalculatorNodeA.java b/java/sca/samples/calculator-distributed/src/main/java/node/LaunchCalculatorNodeA.java index 0025c85f79..3ff6c8969a 100644 --- a/java/sca/samples/calculator-distributed/src/main/java/node/LaunchCalculatorNodeA.java +++ b/java/sca/samples/calculator-distributed/src/main/java/node/LaunchCalculatorNodeA.java @@ -20,7 +20,7 @@ package node; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.launcher.NodeLauncher; import org.osoa.sca.ServiceRuntimeException; @@ -29,7 +29,7 @@ import calculator.CalculatorService; public class LaunchCalculatorNodeA { public static void main(String[] args) throws Exception { - SCANode2 node = null; + SCANode node = null; try { NodeLauncher nodeLauncher = NodeLauncher.newInstance(); diff --git a/java/sca/samples/calculator-distributed/src/test/java/calculator/CalculatorDistributedTestCase.java b/java/sca/samples/calculator-distributed/src/test/java/calculator/CalculatorDistributedTestCase.java index 9c3f06ee53..2a6f3af002 100644 --- a/java/sca/samples/calculator-distributed/src/test/java/calculator/CalculatorDistributedTestCase.java +++ b/java/sca/samples/calculator-distributed/src/test/java/calculator/CalculatorDistributedTestCase.java @@ -22,8 +22,8 @@ package calculator; import junit.framework.Assert;
import org.apache.tuscany.sca.node.SCAClient;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.apache.tuscany.sca.node.launcher.DomainManagerLauncher;
import org.junit.AfterClass;
import org.junit.BeforeClass;
@@ -35,10 +35,10 @@ import org.junit.Test; */
public class CalculatorDistributedTestCase {
- private static SCANode2 manager;
- private static SCANode2 nodeA;
- private static SCANode2 nodeB;
- private static SCANode2 nodeC;
+ private static SCANode manager;
+ private static SCANode nodeA;
+ private static SCANode nodeB;
+ private static SCANode nodeC;
private static CalculatorService calculatorService;
@@ -53,7 +53,7 @@ public class CalculatorDistributedTestCase { manager = managerLauncher.createDomainManager();
manager.start();
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
nodeC = nodeFactory.createSCANodeFromURL("http://localhost:9990/node-config/NodeC");
nodeB = nodeFactory.createSCANodeFromURL("http://localhost:9990/node-config/NodeB");
nodeA = nodeFactory.createSCANodeFromURL("http://localhost:9990/node-config/NodeA");
diff --git a/java/sca/samples/calculator/pom.xml b/java/sca/samples/calculator/pom.xml index df2f8d93dd..4a2216c2e9 100644 --- a/java/sca/samples/calculator/pom.xml +++ b/java/sca/samples/calculator/pom.xml @@ -38,13 +38,13 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> <scope>runtime</scope> </dependency> diff --git a/java/sca/samples/calculator/src/main/java/calculator/CalculatorClient.java b/java/sca/samples/calculator/src/main/java/calculator/CalculatorClient.java index 6dc2cbbe6f..3b2966e96d 100644 --- a/java/sca/samples/calculator/src/main/java/calculator/CalculatorClient.java +++ b/java/sca/samples/calculator/src/main/java/calculator/CalculatorClient.java @@ -20,8 +20,8 @@ package calculator; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * This client program shows how to create an SCA runtime, start it, @@ -30,8 +30,8 @@ import org.apache.tuscany.sca.node.SCANode2Factory; public class CalculatorClient { public static void main(String[] args) throws Exception { - SCANode2Factory factory = SCANode2Factory.newInstance(); - SCANode2 node = factory.createSCANodeFromClassLoader("Calculator.composite", CalculatorClient.class.getClassLoader()); + SCANodeFactory factory = SCANodeFactory.newInstance(); + SCANode node = factory.createSCANodeFromClassLoader("Calculator.composite", CalculatorClient.class.getClassLoader()); node.start(); CalculatorService calculatorService = ((SCAClient)node).getService(CalculatorService.class, "CalculatorServiceComponent"); diff --git a/java/sca/samples/calculator/src/test/java/calculator/CalculatorTestCase.java b/java/sca/samples/calculator/src/test/java/calculator/CalculatorTestCase.java index a723af10c6..1b7476534a 100644 --- a/java/sca/samples/calculator/src/test/java/calculator/CalculatorTestCase.java +++ b/java/sca/samples/calculator/src/test/java/calculator/CalculatorTestCase.java @@ -21,8 +21,8 @@ package calculator; import junit.framework.TestCase; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * This shows how to test the Calculator service component. @@ -30,11 +30,11 @@ import org.apache.tuscany.sca.node.SCANode2Factory; public class CalculatorTestCase extends TestCase { private CalculatorService calculatorService; - private SCANode2 node; + private SCANode node; @Override protected void setUp() throws Exception { - SCANode2Factory factory = SCANode2Factory.newInstance(); + SCANodeFactory factory = SCANodeFactory.newInstance(); node = factory.createSCANodeFromClassLoader("Calculator.composite", getClass().getClassLoader()); node.start(); diff --git a/java/sca/samples/callback-ws-client/pom.xml b/java/sca/samples/callback-ws-client/pom.xml index 594ad10221..c45691febb 100644 --- a/java/sca/samples/callback-ws-client/pom.xml +++ b/java/sca/samples/callback-ws-client/pom.xml @@ -38,7 +38,7 @@ <dependencies>
<dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-impl</artifactId>
+ <artifactId>tuscany-node-impl</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
diff --git a/java/sca/samples/callback-ws-client/src/main/java/myapp/MyClientImpl.java b/java/sca/samples/callback-ws-client/src/main/java/myapp/MyClientImpl.java index 3d94973880..ece769236c 100644 --- a/java/sca/samples/callback-ws-client/src/main/java/myapp/MyClientImpl.java +++ b/java/sca/samples/callback-ws-client/src/main/java/myapp/MyClientImpl.java @@ -22,8 +22,8 @@ import myserver.MyService; import myserver.MyServiceCallback;
import org.apache.tuscany.sca.node.SCAClient;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.osoa.sca.annotations.Reference;
import org.osoa.sca.annotations.Scope;
import org.osoa.sca.annotations.Service;
@@ -49,14 +49,14 @@ public class MyClientImpl implements MyClient, MyServiceCallback { }
public static void main(String[] args) throws Exception {
- SCANode2 node = SCANode2Factory.newInstance().createSCANodeFromClassLoader("myapp.composite", MyClientImpl.class.getClassLoader());
+ SCANode node = SCANodeFactory.newInstance().createSCANodeFromClassLoader("myapp.composite", MyClientImpl.class.getClassLoader());
node.start();
run(node);
System.out.println("Closing the domain");
node.stop();
}
- public static void run(SCANode2 node) throws InterruptedException {
+ public static void run(SCANode node) throws InterruptedException {
MyClient myClient = ((SCAClient)node).getService(MyClient.class, "MyClientComponent");
myClient.aClientMethod();
Thread.sleep(5000); // don't exit before callback arrives
diff --git a/java/sca/samples/callback-ws-client/src/test/java/myapp/CallbackClientTestCase.java b/java/sca/samples/callback-ws-client/src/test/java/myapp/CallbackClientTestCase.java index f11b0adfe4..fb2f6952c4 100644 --- a/java/sca/samples/callback-ws-client/src/test/java/myapp/CallbackClientTestCase.java +++ b/java/sca/samples/callback-ws-client/src/test/java/myapp/CallbackClientTestCase.java @@ -18,8 +18,8 @@ */
package myapp;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -29,12 +29,12 @@ import org.junit.Test; */
public class CallbackClientTestCase {
- private SCANode2 node;
+ private SCANode node;
@Before
public void startServer() throws Exception {
try {
- node = SCANode2Factory.newInstance().createSCANodeFromClassLoader(null, getClass().getClassLoader());
+ node = SCANodeFactory.newInstance().createSCANodeFromClassLoader(null, getClass().getClassLoader());
node.start();
} catch (Exception ex) {
System.out.println(ex.toString());
diff --git a/java/sca/samples/callback-ws-service/pom.xml b/java/sca/samples/callback-ws-service/pom.xml index 4036b3237a..789f981d49 100644 --- a/java/sca/samples/callback-ws-service/pom.xml +++ b/java/sca/samples/callback-ws-service/pom.xml @@ -38,7 +38,7 @@ <dependencies>
<dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-impl</artifactId>
+ <artifactId>tuscany-node-impl</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
diff --git a/java/sca/samples/callback-ws-service/src/main/java/myserver/CallbackServer.java b/java/sca/samples/callback-ws-service/src/main/java/myserver/CallbackServer.java index 9dfead61db..75ef05bc48 100644 --- a/java/sca/samples/callback-ws-service/src/main/java/myserver/CallbackServer.java +++ b/java/sca/samples/callback-ws-service/src/main/java/myserver/CallbackServer.java @@ -20,8 +20,8 @@ package myserver; import java.io.IOException;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
/**
* This server program shows how to create and start an SCA runtime that
@@ -31,7 +31,7 @@ public class CallbackServer { public static void main(String[] args) throws Exception {
- SCANode2 node = SCANode2Factory.newInstance().createSCANodeFromClassLoader("callbackws.composite", null);
+ SCANode node = SCANodeFactory.newInstance().createSCANodeFromClassLoader("callbackws.composite", null);
node.start();
try {
diff --git a/java/sca/samples/callback-ws-service/src/test/java/myserver/CallbackServerTestCase.java b/java/sca/samples/callback-ws-service/src/test/java/myserver/CallbackServerTestCase.java index 4208f7f6b5..e87667cc3e 100644 --- a/java/sca/samples/callback-ws-service/src/test/java/myserver/CallbackServerTestCase.java +++ b/java/sca/samples/callback-ws-service/src/test/java/myserver/CallbackServerTestCase.java @@ -21,8 +21,8 @@ package myserver; import java.io.IOException;
import java.net.Socket;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -32,11 +32,11 @@ import org.junit.Test; */
public class CallbackServerTestCase {
- private SCANode2 node;
+ private SCANode node;
@Before
public void startServer() throws Exception {
- node = SCANode2Factory.newInstance().createSCANodeFromClassLoader("callbackws.composite", null);
+ node = SCANodeFactory.newInstance().createSCANodeFromClassLoader("callbackws.composite", null);
node.start();
}
diff --git a/java/sca/samples/customer-dojo/build-dependency.xml b/java/sca/samples/customer-dojo/build-dependency.xml index 8b59283e03..789fa97324 100644 --- a/java/sca/samples/customer-dojo/build-dependency.xml +++ b/java/sca/samples/customer-dojo/build-dependency.xml @@ -49,6 +49,7 @@ <include name="tuscany-implementation-java-1.4-SNAPSHOT.jar"/> <include name="tuscany-implementation-java-runtime-1.4-SNAPSHOT.jar"/> <include name="tuscany-implementation-java-xml-1.4-SNAPSHOT.jar"/> + <include name="tuscany-implementation-node-1.4-SNAPSHOT.jar"/> <include name="tuscany-implementation-resource-1.4-SNAPSHOT.jar"/> <include name="tuscany-implementation-resource-runtime-1.4-SNAPSHOT.jar"/> <include name="tuscany-interface-1.4-SNAPSHOT.jar"/> @@ -56,6 +57,8 @@ <include name="tuscany-interface-java-jaxws-1.4-SNAPSHOT.jar"/> <include name="tuscany-interface-java-xml-1.4-SNAPSHOT.jar"/> <include name="tuscany-monitor-1.4-SNAPSHOT.jar"/> + <include name="tuscany-node2-api-1.4-SNAPSHOT.jar"/> + <include name="tuscany-node2-impl-1.4-SNAPSHOT.jar"/> <include name="tuscany-policy-1.4-SNAPSHOT.jar"/> <include name="tuscany-policy-xml-1.4-SNAPSHOT.jar"/> <include name="tuscany-sca-api-1.4-SNAPSHOT.jar"/> diff --git a/java/sca/samples/domain-management/pom.xml b/java/sca/samples/domain-management/pom.xml index d674decbce..781f77285a 100644 --- a/java/sca/samples/domain-management/pom.xml +++ b/java/sca/samples/domain-management/pom.xml @@ -86,13 +86,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/samples/domain-management/src/main/java/manager/DistributeAndRunComponents.java b/java/sca/samples/domain-management/src/main/java/manager/DistributeAndRunComponents.java index 7981cdb5c6..380d501ab5 100644 --- a/java/sca/samples/domain-management/src/main/java/manager/DistributeAndRunComponents.java +++ b/java/sca/samples/domain-management/src/main/java/manager/DistributeAndRunComponents.java @@ -71,7 +71,7 @@ import org.apache.tuscany.sca.implementation.node.builder.impl.NodeCompositeBuil import org.apache.tuscany.sca.interfacedef.InterfaceContractMapper; import org.apache.tuscany.sca.monitor.Monitor; import org.apache.tuscany.sca.monitor.MonitorFactory; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.launcher.NodeLauncher; import org.apache.tuscany.sca.policy.IntentAttachPointTypeFactory; import org.apache.tuscany.sca.workspace.Workspace; @@ -260,7 +260,7 @@ public class DistributeAndRunComponents { System.out.println(print(domainComposite)); // Now start our SCA nodes - List<SCANode2> runtimeNodes = new ArrayList<SCANode2>(); + List<SCANode> runtimeNodes = new ArrayList<SCANode>(); NodeLauncher launcher = NodeLauncher.newInstance(); for (Component node: cloudComposite.getComponents()) { @@ -286,7 +286,7 @@ public class DistributeAndRunComponents { Contribution dependency = dependencies.get(c); contributions[c] = new org.apache.tuscany.sca.node.launcher.Contribution(dependency.getURI(), dependency.getLocation()); } - SCANode2 runtimeNode = launcher.createNode("http://sample/" + node.getName(), print(runnable), contributions); + SCANode runtimeNode = launcher.createNode("http://sample/" + node.getName(), print(runnable), contributions); // Start the node runtimeNode.start(); @@ -296,7 +296,7 @@ public class DistributeAndRunComponents { System.out.println("Nodes are running, press enter to stop..."); System.in.read(); - for (SCANode2 runtimeNode: runtimeNodes) { + for (SCANode runtimeNode: runtimeNodes) { runtimeNode.stop(); } } diff --git a/java/sca/samples/store-distributed/pom.xml b/java/sca/samples/store-distributed/pom.xml index 5d2256b362..1cd493807e 100644 --- a/java/sca/samples/store-distributed/pom.xml +++ b/java/sca/samples/store-distributed/pom.xml @@ -39,13 +39,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/tools/maven/maven-osgi-junit/pom.xml b/java/sca/tools/maven/maven-osgi-junit/pom.xml index 5787873d62..278ef80f71 100644 --- a/java/sca/tools/maven/maven-osgi-junit/pom.xml +++ b/java/sca/tools/maven/maven-osgi-junit/pom.xml @@ -45,7 +45,7 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher-osgi</artifactId> + <artifactId>tuscany-node-launcher-osgi</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/tools/runtime-inspector/pom.xml b/java/sca/tools/runtime-inspector/pom.xml index 49807b209f..6c5e314e15 100644 --- a/java/sca/tools/runtime-inspector/pom.xml +++ b/java/sca/tools/runtime-inspector/pom.xml @@ -45,7 +45,7 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-impl</artifactId>
+ <artifactId>tuscany-node-impl</artifactId>
<version>1.4-SNAPSHOT</version>
</dependency>
diff --git a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/AssemblyInspector.java b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/AssemblyInspector.java index 55f83f65b3..ff32d1b48f 100644 --- a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/AssemblyInspector.java +++ b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/AssemblyInspector.java @@ -18,35 +18,16 @@ */ package org.apache.tuscany.sca.tools.inspector; -import java.beans.BeanInfo; -import java.beans.IntrospectionException; -import java.beans.Introspector; -import java.beans.PropertyDescriptor; -import java.io.OutputStreamWriter; -import java.io.PrintWriter; -import java.lang.reflect.Field; -import java.lang.reflect.Method; -import java.security.AccessController; -import java.security.PrivilegedAction; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashSet; -import java.util.List; -import java.util.Set; - -import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLOutputFactory; import javax.xml.stream.XMLStreamWriter; -import org.apache.tuscany.sca.assembly.AssemblyFactory; import org.apache.tuscany.sca.assembly.Composite; import org.apache.tuscany.sca.contribution.ModelFactoryExtensionPoint; import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor; import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessorExtensionPoint; import org.apache.tuscany.sca.core.ExtensionPointRegistry; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.impl.NodeImpl; -import org.w3c.dom.Node; /** @@ -55,7 +36,7 @@ import org.w3c.dom.Node; public class AssemblyInspector { - public String assemblyAsString(SCANode2 node) { + public String assemblyAsString(SCANode node) { StringBuffer assemblyString = new StringBuffer(); // get at the node internals diff --git a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RegistryInspector.java b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RegistryInspector.java index 823322daeb..283d5e3df9 100644 --- a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RegistryInspector.java +++ b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RegistryInspector.java @@ -23,8 +23,7 @@ import java.util.Map; import java.util.Set; import org.apache.tuscany.sca.core.DefaultExtensionPointRegistry; -import org.apache.tuscany.sca.core.ExtensionPointRegistry; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.impl.NodeImpl; @@ -33,7 +32,7 @@ import org.apache.tuscany.sca.node.impl.NodeImpl; */ public class RegistryInspector { - public String registryAsString(SCANode2 node) { + public String registryAsString(SCANode node) { StringBuffer extensionPointRegistryString = new StringBuffer("Extension Point Registry \n"); // Get the interesting extension points out of the registry and print them out diff --git a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RuntimeInspector.java b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RuntimeInspector.java index a405264a0d..26080b2e12 100644 --- a/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RuntimeInspector.java +++ b/java/sca/tools/runtime-inspector/src/main/java/org/apache/tuscany/sca/tools/inspector/RuntimeInspector.java @@ -35,7 +35,7 @@ import java.util.List; import java.util.Set; import org.apache.tuscany.sca.assembly.Composite; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.impl.NodeImpl; import org.w3c.dom.Node; @@ -56,7 +56,7 @@ public class RuntimeInspector { } } - public String runtimeAsString(SCANode2 node) { + public String runtimeAsString(SCANode node) { StringBuffer assemblyString = new StringBuffer(); this.out = new PrintWriter(new OutputStreamWriter(System.out), true); diff --git a/java/sca/tools/runtime-inspector/src/test/java/calculator/CalculatorClient.java b/java/sca/tools/runtime-inspector/src/test/java/calculator/CalculatorClient.java index 614b56d489..8001ab7818 100644 --- a/java/sca/tools/runtime-inspector/src/test/java/calculator/CalculatorClient.java +++ b/java/sca/tools/runtime-inspector/src/test/java/calculator/CalculatorClient.java @@ -20,8 +20,8 @@ package calculator; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; /** * This client program shows how to create an SCA runtime, start it, @@ -30,7 +30,7 @@ import org.apache.tuscany.sca.node.SCANode2Factory; public class CalculatorClient { public static void main(String[] args) throws Exception { - SCANode2 node = SCANode2Factory.newInstance().createSCANodeFromClassLoader("Calculator.composite", CalculatorClient.class.getClassLoader()); + SCANode node = SCANodeFactory.newInstance().createSCANodeFromClassLoader("Calculator.composite", CalculatorClient.class.getClassLoader()); node.start(); CalculatorService calculatorService = diff --git a/java/sca/tools/runtime-inspector/src/test/java/org/apache/tuscany/sca/tools/inspector/RegistryInspectorTestCase.java b/java/sca/tools/runtime-inspector/src/test/java/org/apache/tuscany/sca/tools/inspector/RegistryInspectorTestCase.java index a8db7f73f3..0710b670cd 100644 --- a/java/sca/tools/runtime-inspector/src/test/java/org/apache/tuscany/sca/tools/inspector/RegistryInspectorTestCase.java +++ b/java/sca/tools/runtime-inspector/src/test/java/org/apache/tuscany/sca/tools/inspector/RegistryInspectorTestCase.java @@ -24,8 +24,8 @@ import junit.framework.TestCase; import org.apache.tuscany.sca.node.SCAClient;
import org.apache.tuscany.sca.node.SCAContribution;
-import org.apache.tuscany.sca.node.SCANode2;
-import org.apache.tuscany.sca.node.SCANode2Factory;
+import org.apache.tuscany.sca.node.SCANode;
+import org.apache.tuscany.sca.node.SCANodeFactory;
import calculator.CalculatorService;
@@ -35,11 +35,11 @@ import calculator.CalculatorService; public class RegistryInspectorTestCase extends TestCase {
private CalculatorService calculatorService;
- private SCANode2 node;
+ private SCANode node;
@Override
protected void setUp() throws Exception {
- SCANode2Factory nodeFactory = SCANode2Factory.newInstance();
+ SCANodeFactory nodeFactory = SCANodeFactory.newInstance();
node = nodeFactory.createSCANode(new File("src/test/resources/Calculator.composite").toURL().toString(),
new SCAContribution("TestContribution",
new File("src/test/resources").toURL().toString()));
diff --git a/java/sca/tutorials/store/catalog-webapp/pom.xml b/java/sca/tutorials/store/catalog-webapp/pom.xml index 49319381ac..80a8861a99 100644 --- a/java/sca/tutorials/store/catalog-webapp/pom.xml +++ b/java/sca/tutorials/store/catalog-webapp/pom.xml @@ -46,7 +46,7 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-api</artifactId>
+ <artifactId>tuscany-node-api</artifactId>
<version>1.4-SNAPSHOT</version>
<scope>runtime</scope>
</dependency>
@@ -59,7 +59,7 @@ <dependency>
<groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node2-launcher</artifactId>
+ <artifactId>tuscany-node-launcher</artifactId>
<version>1.4-SNAPSHOT</version>
<scope>runtime</scope>
</dependency>
diff --git a/java/sca/tutorials/store/domain/pom.xml b/java/sca/tutorials/store/domain/pom.xml index 41ab070a0c..be3c8c38c9 100644 --- a/java/sca/tutorials/store/domain/pom.xml +++ b/java/sca/tutorials/store/domain/pom.xml @@ -38,7 +38,7 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/tutorials/store/store-client/launch/LaunchStoreClientNode.java b/java/sca/tutorials/store/store-client/launch/LaunchStoreClientNode.java index 8dd1429890..d1a9dfb36c 100644 --- a/java/sca/tutorials/store/store-client/launch/LaunchStoreClientNode.java +++ b/java/sca/tutorials/store/store-client/launch/LaunchStoreClientNode.java @@ -20,7 +20,7 @@ package launch; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.launcher.NodeLauncher; import client.Shopper; @@ -29,7 +29,7 @@ public class LaunchStoreClientNode { public static void main(String[] args) throws Exception { NodeLauncher nodeLauncher = NodeLauncher.newInstance(); - SCANode2 storeClientNode = nodeLauncher.createNodeFromURL("http://localhost:9990/node-config/StoreClientNode"); + SCANode storeClientNode = nodeLauncher.createNodeFromURL("http://localhost:9990/node-config/StoreClientNode"); storeClientNode.start(); SCAClient client = (SCAClient)storeClientNode; diff --git a/java/sca/tutorials/store/store-client/pom.xml b/java/sca/tutorials/store/store-client/pom.xml index b7155ee8cd..bfcc1a912b 100644 --- a/java/sca/tutorials/store/store-client/pom.xml +++ b/java/sca/tutorials/store/store-client/pom.xml @@ -50,13 +50,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/tutorials/store/store-test/pom.xml b/java/sca/tutorials/store/store-test/pom.xml index 057d3713d8..7eb320a804 100644 --- a/java/sca/tutorials/store/store-test/pom.xml +++ b/java/sca/tutorials/store/store-test/pom.xml @@ -50,13 +50,13 @@ <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-launcher</artifactId> + <artifactId>tuscany-node-launcher</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-api</artifactId> + <artifactId>tuscany-node-api</artifactId> <version>1.4-SNAPSHOT</version> </dependency> diff --git a/java/sca/tutorials/store/store-test/test/StoreSupplierTestCase.java b/java/sca/tutorials/store/store-test/test/StoreSupplierTestCase.java index 26d3d49b78..5efec4ee2c 100644 --- a/java/sca/tutorials/store/store-test/test/StoreSupplierTestCase.java +++ b/java/sca/tutorials/store/store-test/test/StoreSupplierTestCase.java @@ -23,7 +23,7 @@ import junit.framework.Assert; import junit.framework.TestCase; import org.apache.tuscany.sca.node.SCAClient; -import org.apache.tuscany.sca.node.SCANode2; +import org.apache.tuscany.sca.node.SCANode; import org.apache.tuscany.sca.node.launcher.DomainManagerLauncher; import org.apache.tuscany.sca.node.launcher.NodeLauncher; import org.junit.After; @@ -40,10 +40,10 @@ import client.Shopper; */ public class StoreSupplierTestCase { - private SCANode2 domainManager; - private SCANode2 storeSupplierNode; - private SCANode2 storeCatalogsNode; - private SCANode2 storeClientNode; + private SCANode domainManager; + private SCANode storeSupplierNode; + private SCANode storeCatalogsNode; + private SCANode storeClientNode; @Before public void setup() throws Exception { diff --git a/java/sca/vtest/java-api/annotations/destroy/pom.xml b/java/sca/vtest/java-api/annotations/destroy/pom.xml index 9ace2399be..57477d1bbb 100644 --- a/java/sca/vtest/java-api/annotations/destroy/pom.xml +++ b/java/sca/vtest/java-api/annotations/destroy/pom.xml @@ -32,7 +32,7 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> diff --git a/java/sca/vtest/java-api/annotations/destroy/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/destroy/DestroyAnnotationTestCase.java b/java/sca/vtest/java-api/annotations/destroy/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/destroy/DestroyAnnotationTestCase.java index 1d10679a8c..f3b2f28200 100644 --- a/java/sca/vtest/java-api/annotations/destroy/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/destroy/DestroyAnnotationTestCase.java +++ b/java/sca/vtest/java-api/annotations/destroy/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/destroy/DestroyAnnotationTestCase.java @@ -25,8 +25,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.junit.Test; import org.osoa.sca.ServiceRuntimeException; @@ -47,8 +47,8 @@ public class DestroyAnnotationTestCase { */ @Test public void atDestroyProper() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/proper/AService.composite").toURL().toString(), + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/proper/AService.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/proper").toURL().toString())); node.start(); @@ -69,9 +69,9 @@ public class DestroyAnnotationTestCase { */ @Test public void atDestroyProtectedMethod() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err1/AServiceErr1.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err1/AServiceErr1.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err1").toURL().toString())); Assert.fail(); @@ -94,9 +94,9 @@ public class DestroyAnnotationTestCase { */ @Test public void atDestroyPrivateMethod() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err2/AServiceErr2.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err2/AServiceErr2.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err2").toURL().toString())); Assert.fail(); @@ -119,9 +119,9 @@ public class DestroyAnnotationTestCase { */ @Test public void atDestroyNonVoidReturnType() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err3/AServiceErr3.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err3/AServiceErr3.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err3").toURL().toString())); Assert.fail(); @@ -144,9 +144,9 @@ public class DestroyAnnotationTestCase { */ @Test public void atDestroyMethodWithArgs() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err4/AServiceErr4.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err4/AServiceErr4.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err4").toURL().toString())); Assert.fail(); diff --git a/java/sca/vtest/java-api/annotations/init/pom.xml b/java/sca/vtest/java-api/annotations/init/pom.xml index 68e6052b04..b2393947f8 100644 --- a/java/sca/vtest/java-api/annotations/init/pom.xml +++ b/java/sca/vtest/java-api/annotations/init/pom.xml @@ -32,7 +32,7 @@ <dependencies> <dependency> <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-node2-impl</artifactId> + <artifactId>tuscany-node-impl</artifactId> <version>1.4-SNAPSHOT</version> </dependency> <dependency> diff --git a/java/sca/vtest/java-api/annotations/init/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/init/InitAnnotationTestCase.java b/java/sca/vtest/java-api/annotations/init/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/init/InitAnnotationTestCase.java index 65ccc9838d..0dbccd8611 100644 --- a/java/sca/vtest/java-api/annotations/init/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/init/InitAnnotationTestCase.java +++ b/java/sca/vtest/java-api/annotations/init/src/test/java/org/apache/tuscany/sca/vtest/javaapi/annotations/init/InitAnnotationTestCase.java @@ -25,8 +25,8 @@ import junit.framework.Assert; import org.apache.tuscany.sca.node.SCAClient; import org.apache.tuscany.sca.node.SCAContribution; -import org.apache.tuscany.sca.node.SCANode2; -import org.apache.tuscany.sca.node.SCANode2Factory; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; import org.junit.Test; import org.osoa.sca.ServiceRuntimeException; @@ -50,8 +50,8 @@ public class InitAnnotationTestCase { */ @Test public void atInitProper() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/proper/AService.composite").toURL().toString(), + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/proper/AService.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/proper").toURL().toString())); node.start(); @@ -74,9 +74,9 @@ public class InitAnnotationTestCase { */ @Test public void atInitProtectedMethod() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err1/AServiceErr1.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err1/AServiceErr1.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err1").toURL().toString())); Assert.fail(); @@ -100,9 +100,9 @@ public class InitAnnotationTestCase { */ @Test public void atInitPrivateMethod() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err2/AServiceErr2.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err2/AServiceErr2.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err2").toURL().toString())); Assert.fail(); @@ -126,9 +126,9 @@ public class InitAnnotationTestCase { */ @Test public void atInitNonVoidReturnType() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err3/HelloWorldErr3.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err3/HelloWorldErr3.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err3").toURL().toString())); Assert.fail(); @@ -152,9 +152,9 @@ public class InitAnnotationTestCase { */ @Test public void atInitMethodWithArgs() throws Exception { - SCANode2Factory nodeFactory = SCANode2Factory.newInstance(); + SCANodeFactory nodeFactory = SCANodeFactory.newInstance(); try { - SCANode2 node = nodeFactory.createSCANode(new File("src/main/resources/err4/HelloWorldErr4.composite").toURL().toString(), + SCANode node = nodeFactory.createSCANode(new File("src/main/resources/err4/HelloWorldErr4.composite").toURL().toString(), new SCAContribution("TestContribution", new File("src/main/resources/err4").toURL().toString())); Assert.fail(); |