diff options
Diffstat (limited to 'sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast')
4 files changed, 11 insertions, 0 deletions
diff --git a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/server.xml b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/server.xml index 6e282e1f12..98474d2cf4 100644 --- a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/server.xml +++ b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/server.xml @@ -22,6 +22,7 @@ <target name="run">
<java classpath="${runtime_classpath}" classname="org.apache.tuscany.sca.node.launcher.NodeMain" fork="true">
+ <sysproperty key="org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding" value="{http://tuscany.apache.org/xmlns/sca/1.1}binding.rmi"/>
<arg value="-node"/>
<arg value="./server-config.xml"/>
<!-- Give the server 60 seconds to stay -->
diff --git a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Client.java b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Client.java index 5df68b8f2f..d94c9850b5 100644 --- a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Client.java +++ b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Client.java @@ -21,6 +21,7 @@ package itest; import java.net.URI;
+import org.apache.tuscany.sca.binding.rmi.RMIBinding;
import org.apache.tuscany.sca.node.Node;
import org.apache.tuscany.sca.node.NodeFactory;
import org.junit.AfterClass;
@@ -33,6 +34,7 @@ public class Client { @BeforeClass
public static void setUpBeforeClass() throws Exception {
+ System.setProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding", RMIBinding.TYPE.toString());
clientNode = NodeFactory.newInstance().createNode(URI.create("tuscany:default"), "../helloworld-client/target//classes");
clientNode.start();
}
@@ -46,6 +48,7 @@ public class Client { if (clientNode != null) {
clientNode.stop();
}
+ System.clearProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding");
}
public static void main(String[] args) throws Exception {
diff --git a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/SCAClient.java b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/SCAClient.java index 67f2c913dc..da5ab5a27c 100644 --- a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/SCAClient.java +++ b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/SCAClient.java @@ -23,12 +23,14 @@ import itest.nodes.Helloworld; import java.net.URI; +import org.apache.tuscany.sca.binding.rmi.RMIBinding; import org.apache.tuscany.sca.node.NodeFactory; import org.oasisopen.sca.client.SCAClientFactory; public class SCAClient { public void testSCAClient() throws Exception { + System.setProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding", RMIBinding.TYPE.toString()); // The configuration required when running with sca-client-rmi and endpoint-hazelcast-rmi //SCAClientFactory factory = SCAClientFactory.newInstance(URI.create("tuscanyclient:default?remotes=192.168.247.1:14820")); @@ -56,6 +58,7 @@ public class SCAClient { // or just rely on the runtime hosting the classes using the SCAClient // when it's on its way down NodeFactory.getInstance().destroy(); + System.clearProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding"); } public static void main(String[] args) throws Exception { diff --git a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Service.java b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Service.java index dbccfd4407..51166fbef4 100644 --- a/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Service.java +++ b/sca-java-2.x/trunk/itest/nodes/two-nodes-two-vms-hazelcast/src/test/java/itest/Service.java @@ -21,6 +21,7 @@ package itest; import java.net.URI;
+import org.apache.tuscany.sca.binding.rmi.RMIBinding;
import org.apache.tuscany.sca.node.Node;
import org.apache.tuscany.sca.node.NodeFactory;
import org.junit.AfterClass;
@@ -33,6 +34,8 @@ public class Service { @BeforeClass
public static void setUpBeforeClass() throws Exception {
+ System.setProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding", RMIBinding.TYPE.toString());
+
serviceNode = NodeFactory.newInstance().createNode(URI.create("tuscany:default"), "../helloworld-service/target/classes");
serviceNode.start();
}
@@ -48,6 +51,7 @@ public class Service { if (serviceNode != null) {
serviceNode.stop();
}
+ System.clearProperty("org.apache.tuscany.sca.binding.sca.provider.SCABindingMapper.mappedBinding");
}
public static void main(String[] args) throws Exception {
|