/** * Invoked when any TCP connectivity issue is detected, i.e. failure to establish * the TCP connection, failure to send a message, missed heartbeat, etc. */ protected void handleTcpConnectionFailure(String error, @Nullable Throwable ex) { if (logger.isInfoEnabled()) { logger.info("TCP connection failure in session " + this.sessionId + ": " + error, ex); } try { sendStompErrorFrameToClient(error); } finally { try { clearConnection(); } catch (Throwable ex2) { if (logger.isDebugEnabled()) { logger.debug("Failure while clearing TCP connection state in session " + this.sessionId, ex2); } } } }
@Override public void afterConnectionClosed() { if (this.tcpConnection == null) { return; } try { if (logger.isDebugEnabled()) { logger.debug("TCP connection to broker closed in session " + this.sessionId); } sendStompErrorFrameToClient("Connection to broker closed."); } finally { try { // Prevent clearConnection() from trying to close this.tcpConnection = null; clearConnection(); } catch (Throwable ex) { // Shouldn't happen with connection reset beforehand } } }
/** * Invoked when any TCP connectivity issue is detected, i.e. failure to establish * the TCP connection, failure to send a message, missed heartbeat, etc. */ protected void handleTcpConnectionFailure(String error, @Nullable Throwable ex) { if (logger.isInfoEnabled()) { logger.info("TCP connection failure in session " + this.sessionId + ": " + error, ex); } try { sendStompErrorFrameToClient(error); } finally { try { clearConnection(); } catch (Throwable ex2) { if (logger.isDebugEnabled()) { logger.debug("Failure while clearing TCP connection state in session " + this.sessionId, ex2); } } } }
@Override public void afterConnectionClosed() { if (this.tcpConnection == null) { return; } try { if (logger.isDebugEnabled()) { logger.debug("TCP connection to broker closed in session " + this.sessionId); } sendStompErrorFrameToClient("Connection to broker closed."); } finally { try { // Prevent clearConnection() from trying to close this.tcpConnection = null; clearConnection(); } catch (Throwable ex) { // Shouldn't happen with connection reset beforehand } } }
/** * Invoked when any TCP connectivity issue is detected, i.e. failure to establish * the TCP connection, failure to send a message, missed heartbeat, etc. */ protected void handleTcpConnectionFailure(String error, @Nullable Throwable ex) { if (logger.isInfoEnabled()) { logger.info("TCP connection failure in session " + this.sessionId + ": " + error, ex); } try { sendStompErrorFrameToClient(error); } finally { try { clearConnection(); } catch (Throwable ex2) { if (logger.isDebugEnabled()) { logger.debug("Failure while clearing TCP connection state in session " + this.sessionId, ex2); } } } }
@Override public void afterConnectionClosed() { if (this.tcpConnection == null) { return; } try { if (logger.isDebugEnabled()) { logger.debug("TCP connection to broker closed in session " + this.sessionId); } sendStompErrorFrameToClient("Connection to broker closed."); } finally { try { // Prevent clearConnection() from trying to close this.tcpConnection = null; clearConnection(); } catch (Throwable ex) { // Shouldn't happen with connection reset beforehand } } }
/** * Invoked when any TCP connectivity issue is detected, i.e. failure to establish * the TCP connection, failure to send a message, missed heartbeat, etc. */ protected void handleTcpConnectionFailure(String error, @Nullable Throwable ex) { if (logger.isInfoEnabled()) { logger.info("TCP connection failure in session " + this.sessionId + ": " + error, ex); } try { sendStompErrorFrameToClient(error); } finally { try { clearConnection(); } catch (Throwable ex2) { if (logger.isDebugEnabled()) { logger.debug("Failure while clearing TCP connection state in session " + this.sessionId, ex2); } } } }
@Override public void afterConnectionClosed() { if (this.tcpConnection == null) { return; } try { if (logger.isDebugEnabled()) { logger.debug("TCP connection to broker closed in session " + this.sessionId); } sendStompErrorFrameToClient("Connection to broker closed."); } finally { try { // Prevent clearConnection() from trying to close this.tcpConnection = null; clearConnection(); } catch (Throwable ex) { // Shouldn't happen with connection reset beforehand } } }