permaculture playing cards*
The moose likes Servlets and the fly likes ClientAbortException:  java.net.SocketException: Connection reset by peer Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "ClientAbortException:  java.net.SocketException: Connection reset by peer" Watch "ClientAbortException:  java.net.SocketException: Connection reset by peer" New topic
Author

ClientAbortException: java.net.SocketException: Connection reset by peer

Scott Duncan
Ranch Hand

Joined: Nov 01, 2002
Posts: 363
We are writing a fairly large file to the OutputStream of the response in a servlet. On IE (not FF or Safari) we get this error. Any ideas? The code is as follows:



No more rhymes! I mean it!<br /> <br />Does anybody want a peanut?
Scott Duncan
Ranch Hand

Joined: Nov 01, 2002
Posts: 363
FYI, we figured this out. It's a general issue in IE
http://support.microsoft.com/kb/812935 that when using HTTPS to download files the response header can't contain "Cache-Control : no-cache", or
"Cache-Control: no-store".

We simply took out the previous headers and added this:



Thanks to David Mortellaro for finding this.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: ClientAbortException: java.net.SocketException: Connection reset by peer
 
Similar Threads
Writing non text file
File copy: Java Program or OS Command which is faster
Handling an Ctrl-C in an Servlet
handling UTF-8
ArrayIndexOutOfBounds Exception on OutputSteam write()