* Sets up the fixture, connect to xmlBlaster 3 times.
*/
protected void setUp() {
ConnectQos connectQos;
try {
Global glob1 = glob.getClone(null);
con1 = glob1.getXmlBlasterAccess(); // Find orb
connectQos = new ConnectQos(glob1, "con1", "secret");
con1.connect(connectQos, new I_Callback() {
public String update(String cbSessionId, UpdateKey updateKey, byte[] content, UpdateQos updateQos) {
log.info("Reveiving asynchronous message '" + updateKey.getOid() + "' in default handler");
numReceived1++;
assertEquals("Message not expected", "command-navigation", updateKey.getOid());
messageArrived1.append("OK");
return "";
}
});
Global glob2 = glob.getClone(null);
con2 = glob2.getXmlBlasterAccess(); // Find orb
connectQos = new ConnectQos(glob2, "con2", "secret");
con2.connect(connectQos, new I_Callback() {
public String update(String cbSessionId, UpdateKey updateKey, byte[] content, UpdateQos updateQos) {
log.info("Reveiving asynchronous message '" + updateKey.getOid() + "' in default handler");
numReceived2++;
assertEquals("Message not expected", "command-radar-1", updateKey.getOid());
messageArrived2.append("OK");
return "";
}
});
Global glob3 = glob.getClone(null);
con3 = glob3.getXmlBlasterAccess(); // Find orb
connectQos = new ConnectQos(glob3, "con3", "secret");
con3.connect(connectQos, new I_Callback() {
public String update(String cbSessionId, UpdateKey updateKey, byte[] content, UpdateQos updateQos) {
log.info("Reveiving asynchronous message '" + updateKey.getOid() + "' in default handler");
numReceived3++;