hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject [HttpCommon] Classic IO code refactored
Date Fri, 02 Sep 2005 20:31:57 GMT
Folks,

I have completely refactored the HTTP data receiver and transmitter
classes based on the classic IO. As incredible as it may sound this
resulted in almost four-fold performance improvement on one byte and
line read operations. Now classic IO completely decimates NIO on my
Linux box

Before refactoring
=================
Old IO byte array read average time (ms): 208
NIO byte array read average time (ms): 212
Old IO one byte read average time (ms): 642
NIO one byte read average time (ms): 176
Old IO one line read average time (ms): 819
NIO one line read average time (ms): 326

After refactoring
=================
Old IO byte array read average time (ms): 193
NIO byte array read average time (ms): 209
Old IO one byte read average time (ms): 107
NIO one byte read average time (ms): 173
Old IO one line read average time (ms): 164
NIO one line read average time (ms): 328

Source:
http://svn.apache.org/repos/asf/jakarta/httpclient/trunk/http-common/src/test/tests/performance/HttpNIOvsHttpOIOTest.java

In my opinion there's no longer a single reason to keep NIO in the
HttpCommon package

Oleg
PS: I'll be on vacation from tomorrow until next Saturday, Sept 10th.
Talk to you in a week


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-dev-help@jakarta.apache.org


Mime
View raw message