Hi Mark,

I gave that a go, but again, it didn't seem to make much difference. My cpu% still ramps up once I get up to 1000 connections at 128 bytes every 1/4 of a second with a 64 byte response.

This is how I write to the session:

       IoSession io = (IoSession)session.getSource();
       ByteBuffer buf = ByteBuffer.allocate(b.length);
       buf.put(b); buf.position(0);
       buf.limit(b.length);
       io.write(buf);

Is there a quicker way of getting a byte array to Mina - could this be the problem? I'm guessing a bit here!

Cheers,
Richard.
--

Mark Webb wrote:
What about...

acceptor = new SocketAcceptor(Runtime.getRuntime().availableProcessors()+1,
   Executors.newFixedThreadPool(50));



Reply via email to