Mark wrote: > Does not sound like it is working as planned. Do you have a test program > that demonstrates this behavior?
Yes. You can test the code below using netcat: nc -i 5 localhost 1234 ***************************************************** public class WriteRequestSnafuServer { private static final int PORT = 1234; public static void main(String[] args) throws Exception { SocketAcceptor acceptor = new NioSocketAcceptor(Runtime.getRuntime().availableProcessors() + 1); acceptor.setReuseAddress(true); DefaultIoFilterChainBuilder chain = acceptor.getFilterChain(); WriteThrottleFilter writeThrottleFilter = new WriteThrottleFilter(WriteThrottlePolicy.BLOCK); chain.addLast("executor", new ExecutorFilter(Executors.newFixedThreadPool(16))); chain.addLast("writeThrottleFilter", writeThrottleFilter); acceptor.setHandler(new IoHandlerAdapter() { @Override public void sessionOpened(IoSession iosession) throws Exception { System.out.println("Session Opened"); super.sessionOpened(iosession); for (int i = 0; i < 50000; i++) { IoBuffer wbuf = IoBuffer.wrap(("Message #" + i + ": The brown fox jumps over the lazy dog.\n").getBytes()); long beginWrite = System.currentTimeMillis(); WriteFuture wf = iosession.write(wbuf); wf.awaitUninterruptibly(10); long endWrite = System.currentTimeMillis(); long duration = endWrite - beginWrite; if (duration > 20) { System.out.println("Time for write:" + duration + " ms"); } } } @Override public void exceptionCaught(IoSession iosession, Throwable t) throws Exception { System.out.println(t.getMessage()); } }); // Bind acceptor.bind(new InetSocketAddress(PORT)); System.out.println("Listening on port " + PORT); } } ***************************************************************** -- Luis Neves