directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vinod Panicker <vino...@gmail.com>
Subject Re: [mina] Performance issues
Date Thu, 24 Mar 2005 06:51:21 GMT
On Thu, 24 Mar 2005 15:13:23 +0900, Trustin Lee <trustin@gmail.com> wrote:
> Hi Vinod,
> 
> On Thu, 24 Mar 2005 10:50:21 +0530, Vinod Panicker <vinod.p@gmail.com> wrote:
> <snip/>
> 
> > Alright... Latest stats are as follows -
> >

-- snip --

Latest stats stand at 50K connections now.  Too much CPU usage.

-- snip --

> >
> > I agree with what Berin says, and every Internet server should know
> > its limits.  Thats where these benchmarks help - we can estimate what
> > kind of load is MAX, under which the system can still provide expected
> > performance levels.
> 
> We'll be able to create a IoHandlerFilter that limits the maximum
> number of connected clients.

I think this Filter should consider most DOS attack scenarios.  Would
be excellent to have a Network library that takes care of most DOS
issues out of the box.  Makes a lot of sense for servers such as
ApacheDS as well, as a H/W firewall becomes less necessary.

-- snip --

> 
> I think we can provide your testing code into separate subproject.

Whatever you guys think is best.  Suggestions welcome for the benchmark suite.

-- snip --

> 
> You're right.  I've just added SocketAcceptor.get/setBacklog() method.
>  So you can:
> 
> ((SocketAcceptor) ioProtocolAcceptor.getIoAcceptor()).setBacklog( yourBacklog );

Thanks!

-- snip --

> 
> I reduced it to 1K and reconfigurable, and added
> SocketSessionConfig.setSessionReceiveBufferSize(...). :)

Alex will get a shock when he sees the performance now :)

> 
> > 3.  Client/Server CPU usage.  The number of connections per second
> > steadily keeps decreasing as the total connections increase.  Client &
> > Server both are at 100% CPU.  That is what is weird.  I'm aiming to
> > isolate the problem.  I'm currently a bit doubtful about the way the
> > Connector works, but wont be able to point out anything concrete until
> > more permutations & combinations are tried.
> 
> Hmm, interesting.  This might be related with
> processIdleSessions(...).  Could you try to disable it?

Couldnt find anything like this?  Where's it supposed to be?

> 
> > I'm expecting that MINA should be able to take 100K connections on the
> > server.  It cant go over 65K for the client due to lack of available
> > port numbers.
> 
> Can we accept more than 64K connections on the server side?

Yes, of course!  The server, unlike the client is not constricted by
the number of ports available, since it is simply using a file
descriptor per connection rather than a port number.

So theoretically, it should only be limited by Hardware and OS limits.
 And since OS limits have been recently upped significantly (eg the
2.6 kernel series and Windows 2003 server), this should not be a
problem at all.

> 
> <snip/>
> 
> Thanks for your consistent contribution! :)

Most welcome.  I just hope you will keep responding to valid change
requests.  Its high time that Java has a carrier-grade network
library.

Regards,
Vinod.

Mime
View raw message