Thanks for the response.

So I'm sending 8MBs of data at a time to a server which stores it. Later on,
that server needs to send it back. What I don't understand is that I never
get this error when I'm writing from the sender to the receiver, but instead
it only happens from sending back from receiver to the original sender. Both
servers are using Restlet.

the connection made looks like the following:
<code>
URL getChunkDataURL = new URL("http://"; + responseArray.get(0) +
"/readchunk/"
                                                      +
responseArray.get(1));
URLConnection getChunkDataURLConnection = getChunkDataURL.openConnection();
BufferedReader in = new BufferedReader(new InputStreamReader(
                      getChunkDataURLConnection.getInputStream()));
bytesRead = in.read(buffer);
in.close();
</code>

where buffer is a char array of size 8MB exactly.

What happens is the socket just closes randomly so I lose pieces of data.

Thanks,
Kevin

--
View this message in context: 
http://restlet-discuss.1400322.n2.nabble.com/java-net-SocketException-Broken-pipe-tp6306663p6310603.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2725243

Reply via email to