You ever get an answer to this? On Friday, March 15, 2013 at 9:24:30 PM UTC-7, Tong Sun wrote: > > Not to question the decision, but that seem really counter-intuitive, as I > think people stop web requests in the middle all the times. > > Why go insists on reading the _entire_ response body > before resp.Body.Close(), even some 700mb has to be read and discarded? > Again, just curious to know. Also, any other method that allow people > stop in the middle of web requests? > > Thanks > > On Friday, March 15, 2013 9:10:32 PM UTC-4, Dave Cheney wrote: >> >> That is correct. You _must_ close the response body, and closing the >> response body _must_ read all the data on the connection so it can >> return the connection to the connection pool. >> >> On Sat, Mar 16, 2013 at 12:06 PM, Wendal Chen <wenda...@gmail.com> >> wrote: >> > So, I can't close it before read ALL data? >> > >> > >> > 2013/3/16 Dave Cheney <da...@cheney.net> >> >> >> >> Calling resp.Body.Close() must read the _entire_ response body (some >> >> 700mb). >> >
-- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/bd6e7c51-f209-46ef-9d17-5e58a5d383d2%40googlegroups.com.