@Override public void readyForEvents(InternalDistributedSystem system) { synchronized (lock) { this.sentClientReady = true; } QueueConnectionImpl primary = null; while (primary == null) { try { primary = (QueueConnectionImpl) getAllConnections().getPrimary(); } catch (NoSubscriptionServersAvailableException ignore) { primary = null; break; } if (primary.sendClientReady()) { try { logger.info("Sending ready for events to primary: {}", primary); ReadyForEventsOp.execute(pool, primary); } catch (Exception e) { if (logger.isDebugEnabled()) { logger.debug("Error sending ready for events to {}", primary, e); } primary.destroy(); primary = null; } } } }
if (primary != null && sentClientReady && primary.sendClientReady()) { readyForEventsAfterFailover(primary);
boolean haveSentClientReady = this.sentClientReady; if (haveSentClientReady) { cnx.sendClientReady();