clientOptions.setUseSeparateListener(true);
serviceClient.setOptions(clientOptions);
Callback callback1 = new TestCallback ("Callback 1");
serviceClient.sendReceiveNonBlocking (getEchoOMBlock("echo1",sequenceKey),callback1);
Callback callback2 = new TestCallback ("Callback 2");
serviceClient.sendReceiveNonBlocking(getEchoOMBlock("echo2",sequenceKey),callback2);
Callback callback3 = new TestCallback ("Callback 3");
serviceClient.sendReceiveNonBlocking(getEchoOMBlock("echo3",sequenceKey),callback3);
Callback callback4 = new TestCallback ("Callback 4");
serviceClient.sendReceiveNonBlocking(getEchoOMBlock("echo4",sequenceKey),callback4);
clientOptions.setProperty(SandeshaClientConstants.LAST_MESSAGE, "true");
Callback callback5 = new TestCallback ("Callback 5");
serviceClient.sendReceiveNonBlocking(getEchoOMBlock("echo5",sequenceKey),callback5);
while (!callback5.isComplete()) {
Thread.sleep(1000);
}
Thread.sleep(4000);