异常问题Software caused connection abort: socket write error

异常求解决

今天碰到一个异常
src = "/12319/upload/events/20170629130951802.wav"
然后在jsp页面里面写了个window.open
window.open(src, '12319Audio', 'height=150px,width=400px,top=150,left=100,toolbar=no, menubar=no,scrollbars=no,resizable=no,location=no,status=no');

谁有没有碰到过类似的情况,有什么解决方案没??

 

这个打开新窗口的操作有时不会报异常,一旦第一个异常出现后,其他的都会出现异常

关键这个操作是纯粹的打开一个URL地址,和后台的唯一关系就是进了一次过滤器,网上实在搜不到答案


最后的结果是音乐文件可以正常播放,而且所有的功能都正常运行,就是在MyEclipse的console栏里面报异常

 

ClientAbortException:  java.net.SocketException: Software caused connection abort: socket write error

at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.java:388)

at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:462)

at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:366)

at org.apache.catalina.connector.OutputBuffer.writeBytes(OutputBuffer.java:413)

at org.apache.catalina.connector.OutputBuffer.write(OutputBuffer.java:401)

at org.apache.catalina.connector.CoyoteOutputStream.write(CoyoteOutputStream.java:91)

at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.java:2116)

at org.apache.catalina.servlets.DefaultServlet.copy(DefaultServlet.java:1948)

at org.apache.catalina.servlets.DefaultServlet.serveResource(DefaultServlet.java:1006)

at org.apache.catalina.servlets.DefaultServlet.doGet(DefaultServlet.java:411)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at com.asam.buz.common.filter.LoggerMDCFilter.doFilterInternal(LoggerMDCFilter.java:18)

at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:108)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at com.asam.buz.common.filter.FlashFilter.doFilterInternal(FlashFilter.java:25)

at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:108)

2017-06-29 18:03:03.209 [http-bio-8080-exec-10] DEBUG com.asam.buz.common.filter.UEditorUploadFilter - url: /12319/upload/events/20170629130957576.wav ,self: false

 

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:96)

at com.asam.buz.common.filter.UEditorUploadFilter.doFilter(UEditorUploadFilter.java:69)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)

at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:108)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)

at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)

at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1002)

at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:585)

at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

at java.lang.Thread.run(Thread.java:744)

Caused by: java.net.SocketException: Software caused connection abort: socket write error

at java.net.SocketOutputStream.socketWrite0(Native Method)

at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:113)

at java.net.SocketOutputStream.write(SocketOutputStream.java:159)

at org.apache.coyote.http11.InternalOutputBuffer.realWriteBytes(InternalOutputBuffer.java:215)

at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:462)

at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:366)

at org.apache.coyote.http11.InternalOutputBuffer$OutputStreamOutputBuffer.doWrite(InternalOutputBuffer.java:240)

at org.apache.coyote.http11.filters.IdentityOutputFilter.doWrite(IdentityOutputFilter.java:84)

at org.apache.coyote.http11.AbstractOutputBuffer.doWrite(AbstractOutputBuffer.java:192)

at org.apache.coyote.Response.doWrite(Response.java:504)

at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.java:383)

... 42 more

 

解决办法:

 

 

如下,在拦截器中第一次请求是正常的,但是第二次请求则请求了三次,而前端只能显示一个页面,所以会出异常

 

 

2017-06-29 18:13:04.270 [http-bio-8080-exec-9] DEBUG com.asam.buz.common.filter.UEditorUploadFilter - url: /12319/upload/events/20170629130951802.wav ,self: false

2017-06-29 18:13:10.137 [http-bio-8080-exec-9] DEBUG com.asam.buz.common.filter.UEditorUploadFilter - url: /12319/upload/events/20170629130954778.wav ,self: false

2017-06-29 18:13:10.157 [http-bio-8080-exec-4] DEBUG com.asam.buz.common.filter.UEditorUploadFilter - url: /12319/upload/events/20170629130954778.wav ,self: false

2017-06-29 18:13:10.202 [http-bio-8080-exec-4] ERROR com.asam.buz.common.filter.UEditorUploadFilter -自定义过滤器错误: null

ClientAbortException:  java.net.SocketException: Software caused connection abort: socket write error

at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.java:388)

at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:462)

at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:366)

 

具体怎么解决???????再议,明天用window.load再试一次


str.push('试听');

            $(c).html(str.join("  "));

 

开始使用的是a标签,相当不稳定,不知道哪一次就会发送很多次请求,网上这样说:使用a标签比较简单。但是出错后确实诡异。

 

前端的哥们告诉我,把a标签改成span标签

str.push('试听');

            $(c).html(str.join("  "));

就奇迹般的好了。。。。。。。。。。。。。。。。。


你可能感兴趣的:(Java相关知识)