*/
@Test
public void testServiceRestart() {
System.out.println("SampleNaiveAsyncTestCase.testUpper2");
System.out.println("Starting first node");
Upper upper = node.getService(Upper.class, "SampleNativeAsyncReference");
String r = upper.upper("async");
System.out.println(r);
assertEquals("ASYNC", r);
System.out.println("Stopping first node");
node.stop();
// now start another node and try call back in to get the
// async response to come back
System.out.println("Starting second node");
final NodeFactory nf = NodeFactory.getInstance();
String here = SampleNativeAsyncTestCase.class.getProtectionDomain().getCodeSource().getLocation().toString();
// Create the node using the pattern "name of composite file to start" / Contribution to use
node = nf.createNode("testnativeasync.composite", new Contribution("test", here));
node.start();
upper = node.getService(Upper.class, "SampleNativeAsyncReference");
r = upper.upper2("async2");
System.out.println(r);
assertEquals("ASYNC2", r);
}