.set(Options.WORKER_IO_THREADS, worker.getIoThreadCount()) .set(Options.TCP_NODELAY, true) .set(Options.REUSE_ADDRESSES, true)
@Override protected void doBind(SocketAddress localAddress) throws Exception { XnioWorker worker = ((XnioEventLoop) eventLoop()).ioThread().getWorker(); // use the same thread count as the XnioWorker OptionMap map = options.set(Options.WORKER_IO_THREADS, worker.getIoThreadCount()).getMap(); XnioEventLoop eventLoop = (XnioEventLoop) eventLoop(); synchronized (this) { channel = eventLoop.ioThread().getWorker().createStreamConnectionServer(localAddress, new AcceptListener(), map); // start accepting channel.resumeAccepts(); } }
.set(Options.WORKER_IO_THREADS, worker.getIoThreadCount()) .set(Options.TCP_NODELAY, true) .set(Options.REUSE_ADDRESSES, true)
.set(Options.WORKER_IO_THREADS, worker.getIoThreadCount()) .set(Options.TCP_NODELAY, true) .set(Options.REUSE_ADDRESSES, true)