if (log.isDebugEnabled()) {
log.debug("Reconnecting to router at " + stub.getGossipRouterAddress());
}
if(!isSingleton()){
PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
stub.connect(channel_name, local_addr, UUID.get(local_addr), physical_addrs);
if (log.isDebugEnabled()) {
log.debug("Reconnected to router at " + stub.getGossipRouterAddress());
}
}
else {
for(Protocol p: up_prots.values()) {
if(p instanceof ProtocolAdapter) {
Address local=((ProtocolAdapter)p).local_addr;
String cluster_name=((ProtocolAdapter)p).cluster_name;
PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local));
List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
stub.connect(cluster_name, local, UUID.get(local), physical_addrs);
if (log.isDebugEnabled()) {
log.debug("Reconnected to router at " + stub.getGossipRouterAddress());
}