httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 46295] New: Slow performance when Java client is connecting
Date Tue, 25 Nov 2008 17:19:01 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=46295

           Summary: Slow performance when Java client is connecting
           Product: Apache httpd-2
           Version: 2.2.10
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Core
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: business2008@rodneybeede.com


Created an attachment (id=22945)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=22945)
Example Java program to test Java socket performance to a web server

When using a program written in Java that uses Java sockets (java.io.Socket or
java.nio.SocketChannel) the performance to Apache 2.2.x on a Windows server is
very slow.

Running the web server on the same machine as the Java client and using
127.0.0.1 for the host connects very quickly, but downloading a large file of
31MB in size takes 5.9 seconds.

Using any web browser or wget (win32) on the same machine takes less than 1
second to download the file.  This would seem to indicate a bug in Java, but
when I run the Java program from a Linux machine to the Windows server the same
performance issue occurs.

If I run Apache 2.2.x on a Linux host then running the Java program from either
Windows or on the same Linux machine takes under one second.

If I connect the Java program on the Windows machine to another non-Apache
server on the same Windows machine it pulls data down in under 1 second.

I believe there is some bug in the Windows code for Apache in regards to how it
uses sockets.  This is not a DNS issue since the connection is established
quickly.  The slowness comes during the actual data transfer.


Steps to reproduce:

1.  Windows XP SP3
2.  Apache 2.2.10 for Win32 (default config from msi installer)
3.  Create a 32MB file called LargeDownload.file in the root of your htdocs
4.  Compile the attached Java program on the Windows machine using either Sun
Java 5, Sun Java 6, or jrockit 1.5 (all 32-bit)
5.  Run the Java program on the same Windows machine as where you have Apache
running
6.  Note that it takes ~5.9 seconds to download the file when it should take
under one second.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message