protected void serviceRemoteCommand(Command command) { try { if (command.isBrokerInfo()) { synchronized (this) { remoteBrokerInfo = (BrokerInfo)command; remoteBrokerId = remoteBrokerInfo.getBrokerId(); if (localBrokerId != null) { if (localBrokerId.equals(remoteBrokerId)) { LOG.info("Disconnecting loop back connection."); ServiceSupport.dispose(this); } else { triggerStartBridge(); } } } } else { LOG.warn("Unexpected remote command: {}", command); } } catch (IOException e) { serviceLocalException(e); } }
} else if (command.isBrokerInfo()) { synchronized (this) { localBrokerInfo = (BrokerInfo)command;
LOG.debug("No subscription registered with this network bridge for consumerId: {} for message: {}", md.getConsumerId(), md.getMessage()); } else if (command.isBrokerInfo()) { futureLocalBrokerInfo.set((BrokerInfo) command); } else if (command.isShutdownInfo()) {
serviceRemoteConsumerAdvisory(md.getMessage().getDataStructure()); ackAdvisory(md.getMessage()); } else if (command.isBrokerInfo()) { futureRemoteBrokerInfo.set((BrokerInfo) command); } else if (command instanceof BrokerSubscriptionInfo) {
protected void serviceRemoteCommand(Command command) { try { if (command.isBrokerInfo()) { synchronized (this) { remoteBrokerInfo = (BrokerInfo)command; remoteBrokerId = remoteBrokerInfo.getBrokerId(); if (localBrokerId != null) { if (localBrokerId.equals(remoteBrokerId)) { LOG.info("Disconnecting loop back connection."); ServiceSupport.dispose(this); } else { triggerStartBridge(); } } } } else { LOG.warn("Unexpected remote command: {}", command); } } catch (IOException e) { serviceLocalException(e); } }
protected void serviceRemoteCommand(Command command) { try { if (command.isBrokerInfo()) { synchronized (this) { remoteBrokerInfo = (BrokerInfo)command; remoteBrokerId = remoteBrokerInfo.getBrokerId(); if (localBrokerId != null) { if (localBrokerId.equals(remoteBrokerId)) { LOG.info("Disconnecting loop back connection."); ServiceSupport.dispose(this); } else { triggerStartBridge(); } } } } else { LOG.warn("Unexpected remote command: {}", command); } } catch (IOException e) { serviceLocalException(e); } }
protected void serviceRemoteCommand(Command command) { try { if (command.isBrokerInfo()) { synchronized (this) { remoteBrokerInfo = (BrokerInfo)command; remoteBrokerId = remoteBrokerInfo.getBrokerId(); if (localBrokerId != null) { if (localBrokerId.equals(remoteBrokerId)) { LOG.info("Disconnecting loop back connection."); ServiceSupport.dispose(this); } else { triggerStartBridge(); } } } } else { LOG.warn("Unexpected remote command: {}", command); } } catch (IOException e) { serviceLocalException(e); } }
protected void serviceRemoteCommand(Command command) { try { if (command.isBrokerInfo()) { synchronized (this) { remoteBrokerInfo = (BrokerInfo)command; remoteBrokerId = remoteBrokerInfo.getBrokerId(); if (localBrokerId != null) { if (localBrokerId.equals(remoteBrokerId)) { LOG.info("Disconnecting loop back connection."); ServiceSupport.dispose(this); } else { triggerStartBridge(); } } } } else { LOG.warn("Unexpected remote command: " + command); } } catch (IOException e) { serviceLocalException(e); } }
protected void processCommand(Object o) throws Exception { Command command = (Command) o; if (command.isResponse()) { LOG.error("Unexpected response " + command); } else if (command.isMessageDispatch()) { MessageDispatch messageDispatch = (MessageDispatch) command; ConsumerId consumerId = messageDispatch.getConsumerId(); MultiplexerInput input = consumerIdMultiplexerInputMap.get(consumerId); if (input != null) { input.oneway(messageDispatch); } else { LOG.debug("Couldn't find MultiplexerInput for consumerId:" + consumerId); } } else if (command.isBrokerInfo() || command.isWireFormatInfo()) { //not a lot to do with this } else if (command.getClass() == ConnectionError.class) { ConnectionError ce = (ConnectionError) command; onFailure(ce.getException()); } else { switch (command.getDataStructureType()) { case KeepAliveInfo.DATA_STRUCTURE_TYPE: case ShutdownInfo.DATA_STRUCTURE_TYPE: case ConnectionControl.DATA_STRUCTURE_TYPE: break; default: LOG.warn("Unexpected remote command: {}", command); } } }
protected void processCommand(Object o) throws Exception { Command command = (Command) o; if (command.isResponse()) { LOG.error("Unexpected response " + command); } else if (command.isMessageDispatch()) { MessageDispatch messageDispatch = (MessageDispatch) command; ConsumerId consumerId = messageDispatch.getConsumerId(); MultiplexerInput input = consumerIdMultiplexerInputMap.get(consumerId); if (input != null) { input.oneway(messageDispatch); } else { LOG.debug("Couldn't find MultiplexerInput for consumerId:" + consumerId); } } else if (command.isBrokerInfo() || command.isWireFormatInfo()) { //not a lot to do with this } else if (command.getClass() == ConnectionError.class) { ConnectionError ce = (ConnectionError) command; onFailure(ce.getException()); } else { switch (command.getDataStructureType()) { case KeepAliveInfo.DATA_STRUCTURE_TYPE: case ShutdownInfo.DATA_STRUCTURE_TYPE: case ConnectionControl.DATA_STRUCTURE_TYPE: break; default: LOG.warn("Unexpected remote command: {}", command); } } }
sender.onConsumerControl(control); } else if (command.isBrokerInfo()) {
sender.onConsumerControl(control); } else if (command.isBrokerInfo()) {
} else if (command.isBrokerInfo()) {
} else if (command.isBrokerInfo()) {
} else if (command.isBrokerInfo()) { synchronized (this) { localBrokerInfo = (BrokerInfo)command;
} else if (command.isBrokerInfo()) { synchronized (this) { localBrokerInfo = (BrokerInfo)command;
LOG.debug("No subscription registered with this network bridge for consumerId: {} for message: {}", md.getConsumerId(), md.getMessage()); } else if (command.isBrokerInfo()) { futureLocalBrokerInfo.set((BrokerInfo) command); } else if (command.isShutdownInfo()) {
} else if (command.isBrokerInfo()) {
} else if (command.isBrokerInfo()) {
} else if (command.isBrokerInfo()) {