private void handleError(IOException exception) { UndertowLogger.REQUEST_IO_LOGGER.ioException(exception); currentRequest.setFailed(exception); currentRequest = null; pendingResponse = null; safeClose(connection); }
public void handleEvent(StreamConnection channel) { log.debugf("connection to %s closed", getPeerAddress()); HttpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(HttpClientConnection.this, closeSetter.get()); try { if (pooledBuffer != null) { pooledBuffer.close(); } } catch (Throwable ignored){} for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(HttpClientConnection.this); } HttpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; pendingResponse = null; } } });
currentRequest.setFailed(e); currentRequest = null; pendingResponse = null; try { currentRequest.setFailed(new IOException(MESSAGES.connectionClosed())); currentRequest = null; pendingResponse = null; ex.setFailed(new IOException(UndertowClientMessages.MESSAGES.connectionClosed())); ex = pendingQueue.poll(); safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(new IOException(t));
private void handleError(IOException exception) { UndertowLogger.REQUEST_IO_LOGGER.ioException(exception); currentRequest.setFailed(exception); currentRequest = null; pendingResponse = null; safeClose(connection); }
private void handleError(IOException exception) { UndertowLogger.REQUEST_IO_LOGGER.ioException(exception); currentRequest.setFailed(exception); currentRequest = null; pendingResponse = null; safeClose(connection); }
public void handleEvent(StreamConnection channel) { log.debugf("connection to %s closed", getPeerAddress()); HttpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(HttpClientConnection.this, closeSetter.get()); try { if (pooledBuffer != null) { pooledBuffer.close(); } } catch (Throwable ignored){} for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(HttpClientConnection.this); } HttpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; pendingResponse = null; } } });
public void handleEvent(StreamConnection channel) { log.debugf("connection to %s closed", getPeerAddress()); HttpClientConnection.this.state |= CLOSED; ChannelListeners.invokeChannelListener(HttpClientConnection.this, closeSetter.get()); try { if (pooledBuffer != null) { pooledBuffer.close(); } } catch (Throwable ignored){} for(ChannelListener<ClientConnection> listener : closeListeners) { listener.handleEvent(HttpClientConnection.this); } HttpClientExchange pending = pendingQueue.poll(); while (pending != null) { pending.setFailed(new ClosedChannelException()); pending = pendingQueue.poll(); } if(currentRequest != null) { currentRequest.setFailed(new ClosedChannelException()); currentRequest = null; pendingResponse = null; } } });
currentRequest.setFailed(e); currentRequest = null; pendingResponse = null; try { currentRequest.setFailed(new IOException(MESSAGES.connectionClosed())); currentRequest = null; pendingResponse = null; ex.setFailed(new IOException(UndertowClientMessages.MESSAGES.connectionClosed())); ex = pendingQueue.poll(); safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(new IOException(t));
currentRequest.setFailed(e); currentRequest = null; pendingResponse = null; try { currentRequest.setFailed(new IOException(MESSAGES.connectionClosed())); currentRequest = null; pendingResponse = null; ex.setFailed(new IOException(UndertowClientMessages.MESSAGES.connectionClosed())); ex = pendingQueue.poll(); safeClose(connection); if(currentRequest != null) { currentRequest.setFailed(new IOException(t));