private boolean tryToConnect(InetSocketAddress remote) {
		try {
			client = SocketChannel.open();
			client.configureBlocking(false);
			client.connect(remote);

			selector = Selector.open();

			this.conn = new WebSocket(client,
					new LinkedBlockingQueue<ByteBuffer>(), this, draft,
					Integer.MAX_VALUE);
			if (client != null) {
				client.register(selector, SelectionKey.OP_CONNECT);
			}

		} catch (IOException ex) {
			onIOError(conn, ex);
			return false;
		}

		return true;
	}