At Mon, 05 Feb 2007 14:16:44 -0800, Erik Hetzner wrote: > Hello all, > > The following change to Mongrel::HttpRequest:
[…] > seems to work for me, and vastly improves the speed of the body > processing (quick tests reveal that using IO#read takes about 1 min 40 > secs. and using Socket#recv takes about 9 secs on an 8.5 mb file). I > have been having trouble discovering the difference between read & > recv (I am not a socket developer by any means). Can anybody tell me > what sort of safety one loses by doing this with recv instead of read? > Thanks. As a followup, in case it wasn’t obvious, I was far off base here. I should have realized that something was wrong with such horrible transfer speeds. While it still seems using recv instead of read, and, conversely, send instead of write gives you a very slight speedup, most of my problem here was a runaway while loop in another thread (while true do; end seems to take up a lot of time). best, Erik Hetzner
pgpWPIYpUa8Am.pgp
Description: PGP signature
_______________________________________________ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users