@Override public void run() { if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); } } });
private void handleError(IOException exception) { currentRequest.setFailed(exception); safeClose(connection); }
@Override public void handleEvent(AjpClientChannel channel) { log.debugf("connection to %s closed", getPeerAddress()); AjpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(AjpClientConnection.this, closeSetter.get()); for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(AjpClientConnection.this); } AjpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; } } });
safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(e instanceof IOException ? (IOException) e : new IOException(e));
@Override public void run() { if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); } } });
@Override public void run() { if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); } } });
private void handleError(IOException exception) { currentRequest.setFailed(exception); safeClose(connection); }
private void handleError(IOException exception) { currentRequest.setFailed(exception); safeClose(connection); }
@Override public void handleEvent(AjpClientChannel channel) { log.debugf("connection to %s closed", getPeerAddress()); AjpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(AjpClientConnection.this, closeSetter.get()); for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(AjpClientConnection.this); } AjpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; } } });
@Override public void handleEvent(AjpClientChannel channel) { log.debugf("connection to %s closed", getPeerAddress()); AjpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(AjpClientConnection.this, closeSetter.get()); for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(AjpClientConnection.this); } AjpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; } } });
safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(e instanceof IOException ? (IOException) e : new IOException(e));
safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(e instanceof IOException ? (IOException) e : new IOException(e));