}
public void operationComplete(ChannelFuture future) throws Exception {
if (future.isSuccess()) {
final AtomicBoolean open = new AtomicBoolean(true);
final WebSocket webSocket = new DefaultWebSocket(context.getDirectChannelAccess().getChannel(), open, () -> {
try {
handler.onClose(new DefaultWebSocketClose<>(false, openResult));
} catch (Exception e) {
throw uncheck(e);
}