@Override public void onError(Throwable throwable) { wsProtocolHandler.onError(throwable); wsRemoteEndpointServer.close(); } }
@Override public void onError(Throwable throwable) { wsProtocolHandler.onError(throwable); wsRemoteEndpointServer.close(); } }
@Override public void onError(Throwable throwable) { wsProtocolHandler.onError(throwable); wsRemoteEndpointServer.close(); } }
protected void onTimeout(boolean useDispatch) { if (handler != null) { clearHandler(new SocketTimeoutException(), useDispatch); } close(); }
protected void onTimeout(boolean useDispatch) { if (handler != null) { clearHandler(new SocketTimeoutException(), useDispatch); } close(); }
protected void onTimeout(boolean useDispatch) { if (handler != null) { clearHandler(new SocketTimeoutException(), useDispatch); } close(); }
protected void onTimeout(boolean useDispatch) { if (handler != null) { clearHandler(new SocketTimeoutException(), useDispatch); } close(); }
protected void onTimeout(boolean useDispatch) { if (handler != null) { clearHandler(new SocketTimeoutException(), useDispatch); } close(); }
@Override public void failed(Throwable exc, Void attachment) { if (exc instanceof InterruptedByTimeoutException) { exc = new SocketTimeoutException(); } if (block) { SendResult sr = new SendResult(exc); handler.onResult(sr); } else { wsWriteTimeout.unregister(WsRemoteEndpointImplServer.this); clearHandler(exc, true); close(); } } }, buffers);
@Override public void completed(Long result, Void attachment) { if (block) { long timeout = blockingWriteTimeoutExpiry - System.currentTimeMillis(); if (timeout <= 0) { failed(new SocketTimeoutException(), null); } else { handler.onResult(SENDRESULT_OK); } } else { wsWriteTimeout.unregister(WsRemoteEndpointImplServer.this); clearHandler(null, true); if (close) { close(); } } } @Override
@Override public void failed(Throwable exc, Void attachment) { if (exc instanceof InterruptedByTimeoutException) { exc = new SocketTimeoutException(); } if (block) { SendResult sr = new SendResult(exc); handler.onResult(sr); } else { wsWriteTimeout.unregister(WsRemoteEndpointImplServer.this); clearHandler(exc, true); close(); } } }, buffers);
@Override public void completed(Long result, Void attachment) { if (block) { long timeout = blockingWriteTimeoutExpiry - System.currentTimeMillis(); if (timeout <= 0) { failed(new SocketTimeoutException(), null); } else { handler.onResult(SENDRESULT_OK); } } else { wsWriteTimeout.unregister(WsRemoteEndpointImplServer.this); clearHandler(null, true); if (close) { close(); } } } @Override