Hi ! I did some more tests, with different buffer size. Here are the results :
MINA3 : 10b, 1M msg/s : 28,341 1kb, 1M msg/s : 28,884 10kb, 1M msg/s : 25,603 20kb, 1M msg/s : 21,238 50kb, 500k msg/s : 9,425 100kb, 200k msg/s : 7,637 200kb, 100k msg/s : 2,181 500kb, 50k msg/s : 980 1Mb, 20k msg/s : 462 10Mb, 2k msg/s : 37 64Mb, 500 msg/s : 7 MINA2 : 10b, 1M msg/s : 19,085 1kb, 1M msg/s : 19,409 10kb, 1M msg/s : 13,141 20kb, 1M msg/s : 9,679 50kb, 500k msg/s : 7,025 100kb, 200k msg/s : 4,444 200kb, 100k msg/s : 2,861 500kb, 50k msg/s : 1,550 1Mb, 20k msg/s : 753 10Mb, 2k msg/s : 76 64Mb, 500 msg/s : 11 Netty3 : 10b, 1M msg/s : 26,010 1kb, 1M msg/s : 25,297 10kb, 1M msg/s : 19,883 20kb, 1M msg/s : 12,420 50kb, 500k msg/s : 7,058 100kb, 200k msg/s : 4,719 200kb, 100k msg/s : 3,078 500kb, 50k msg/s : 1,290 1Mb, 20k msg/s : 477 10Mb, 2k msg/s : 17 64Mb, 500 msg/s : 4 I have run those tests more than once, and I haven't seen so much variation in the results. It's interesting to see that all the frameworks have their shiny spots, and dark ones. Typically, MINA 3 is faster up to message size < 200kb, then Netty 3 takes the lead à 200kb, and interestingly, MINA 2 is faster above 200kb. For messages <200kb, MIN3 is faster than Netty3 by 9% up to 71%. It's also faster than MINA 2 by 34% up to 120%. Why do we gat those differences ? I can tell for MINA3 vs MINA 2 : MINA 2 write the data after a having enqueued them, so yu will get more select() calls, when MINA 3 tries its best to write the messages immediately. For messages bigger than the Socket SendBufferSize, MINA 3 does a copy into a DirectBuffer which gets allocated on the fly. It's a costly operation when the message is big. MINA 2 tries to copy only SendBuferSize bytes into the socket at each rounds. All in all, it's assumed that there is a Heap -> Direct buffer conversion done inside the Channel, and that the Channel does cache some DirectBuffer. I guess that we should be able to offer some configuration to the user to tune the performances regardingthe kind of sent messages. -- Regards, Cordialement, Emmanuel Lécharny www.iktek.com