You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by Mark Womack <mw...@bevocal.com> on 2002/07/09 18:50:04 UTC

Socket Performance?

It just seems that one thing leads to another...I was looking through my
Receiver implementation and decided to run some ad-hoc performance tests.  I
configured 3 processes on my machine: 1 with a SocketReceiver (matches
SocketAppender), 2 with SocketAppenders.  The SocketAppenders both connected
to the SocketReceiver, and all processes also had ConsoleAppender
configured.

I had the SocketAppender processes run simultaneously for 20 seconds.  The
SocketReceiver processed all of the logging events sent across the
SocketAppender/SocketReceiver connection.  I tried various permutations in
the implementation (buffered streams input and output, a event queue in the
receiver, etc).  The best performance I ever tracked (mind you, this was
ad-hoc) ~220 events/second for each SocketAppender process.  This means that
with both processes running, the SocketReceiver was processing about ~440
events/second.

I know that there are a lot of variables that will affect this performance,
and I don't have anything to compare this to.  Does this perfomance compare
to other people's experience sending logging events across sockets?  Do we
have some code we use as a benchmark/test?  We should.

And looking at this performance stuff leads me to the previous discussion
about optimizing the serialization of the LoggingEvent object...I think the
most gains will be made with that work.

-Mark

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>