Thanks to all for the explanations. Clearly, HTTP uploads will never be as fast as FTP uploads. Is there anything I can do with my server configuration (Tomcat or Apache) or to my servlet code to optimize HTTP uploads and make them as fast as possible?
Cindy At 07:05 AM 6/13/03 -0500, Will Stranathan wrote: >With FTP, a separate channel is usually opened for transferring the file. >With HTTP, the file is sent over the same port as the rest of the request. >So with FTP, the original socket is used for communicating WHEN the transfer >of the file is complete. With HTTP, the server has to process byte-by-byte >the request to find the markers that separate the fields. That's probably >where the bulk of the problem is. (Depending on your configuration, you may >also want to consider that HTTP servers are optimized for SENDING. FTP >servers are typically optimized for handling either direction efficiently.) > >So, the short answer is FTP is prolly quicker because it just has to write >the bits - it gets external notification when there are no more bits to >write. With HTTP, the server has to process every bit to find when the last >one is received. > > >>From: Cindy Ballreich <[EMAIL PROTECTED]> >>Reply-To: "Jakarta Commons Users List" <[EMAIL PROTECTED]> >>To: [EMAIL PROTECTED] >>Subject: [FileUpload] Speeding up uploads >>Date: Wed, 11 Jun 2003 09:30:52 -0700 >> >> >>This is slightly off-topic since it doesn't specifically refer to >>FileUpload, but I'm not finding info anywhere else so I might as well >>ask... >> >>I've noticed that uploads using multipart/form-data encoding are a lot >>slower than other types of uploads (especially on large files). I've tested >>using org.apache.commons.fileupload, com.oreilly.servlet.multipart, and a >>perl cgi script. All three give the same results. The upload speeds seem to >>be about half that of an ftp upload of the same file on the same type of >>connection. Are there any tricks or techniques for speeding up >>multipart/form-data uploads of large files? >> >>Tomcat 4.1.24 with Apache 1.3.26 (mod_jk) and fileupload 1.0-rc1 on RedHat >>7.3 >> >>--------------------------------------------------------------------- >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] >> > >_________________________________________________________________ >The new MSN 8: smart spam protection and 2 months FREE* >http://join.msn.com/?page=features/junkmail > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
