While publishing SOAP with Attachment, where attachment is of size greater than 10 MB. Socket Exception as connection reset by peer on Wildfly 10.1
adityan Jun 2, 2017 2:31 AMI have deployed my application on Wildfly 10.1.0 Final. I create a SOAP Message with Attachment and publish that SOAP Message. The attachment is stored in database and it is fetched before SOAP Message is published. The SOAP Message is successfully published if the attachment size is less than 10 MB.
When the attachment size is greater than 10 MB following exception occurs:
Caused by: java.net.SocketException: Connection reset by peer: socket write error
361
at java.net.SocketOutputStream.socketWrite0(Native Method)
362
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:111)
363
at java.net.SocketOutputStream.write(SocketOutputStream.java:155)
364
at sun.security.ssl.OutputRecord.writeBuffer(OutputRecord.java:431)
365
at sun.security.ssl.OutputRecord.write(OutputRecord.java:417)
366
at sun.security.ssl.SSLSocketImpl.writeRecordInternal(SSLSocketImpl.java:876)
367
at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:847)
368
at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:123)
369
at org.apache.http.impl.io.SessionOutputBufferImpl.streamWrite(SessionOutputBufferImpl.java:126)
370
at org.apache.http.impl.io.SessionOutputBufferImpl.write(SessionOutputBufferImpl.java:162)
371
at org.apache.http.impl.io.ChunkedOutputStream.flushCacheWithAppend(ChunkedOutputStream.java:124)
372
at org.apache.http.impl.io.ChunkedOutputStream.write(ChunkedOutputStream.java:181)
373
at org.apache.http.entity.ByteArrayEntity.writeTo(ByteArrayEntity.java:116)
374
at org.apache.http.impl.DefaultBHttpClientConnection.sendRequestEntity(DefaultBHttpClientConnection.java:158)
375
at org.apache.http.impl.conn.CPoolProxy.sendRequestEntity(CPoolProxy.java:162)
376
at org.apache.http.protocol.HttpRequestExecutor.doSendRequest(HttpRequestExecutor.java:237)
377
at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:122)
378
at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:271)
379
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184)
380
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88)
381
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
382
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
383
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
384
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107)
385
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:55)
This issue does not occur on other application servers. Is this issue WildFly specific? Is there any troubleshoot in WildFly configuration?