Hi Recently I have been experimenting with mina core 2 and I have a few questions regarding the behaviour of mina in some sample programs I made.
here is the client code. its simple, it simply rams as many messages as possible into the server. http://pastebin.com/m14ac361e Now I made two servers. One mina based, which is simply the date/time echo server as described in the documentation. The second one is a simple "one thread per client" server. Here is the code http://pastebin.com/m3a5a14a7 Now the result from both the servers differ a lot. The second server works in lock step with client and responds to messages without any delay. But with mina server the response is very slow and after about 10 messages the response is almost nill and after a few seconds I start getting out of memory exceptions while creating more date objects. Now I have the following questions (I very good spirit) 1. What is the reason behind this behaviour ? 2. I understand that second server will not be able to scale very much but mina probably will, but does this mean that mina server will not be able to handle high load from few clients but low load from many clients? 3. Is there a solution to this ? IMHO, first server example demonstrates that such high load can be handled at server. Thank you