java - ClientAbortException when using Jersey 2.13 -
i'm using bailiwick of jersey 2.13 in web application retrieving info async. there cases requests take time (i.e. when executing complex reports) until response returns client.
when client not wait async response (leaves page, closes browser, etc.), clientabortexception thrown. behaviour expected flooding log files stack traces because every single async request gets canceled before response returns, prints stack trace.
the stack trace looks this:
oct 15, 2014 2:25:23 pm org.glassfish.jersey.server.serverruntime$responder writeresponse severe: i/o error has occurred while writing response message entity container output stream. org.glassfish.jersey.server.internal.process.mappableexception: clientabortexception: java.io.ioexception @ org.glassfish.jersey.server.internal.mappableexceptionwrapperinterceptor.aroundwriteto(mappableexceptionwrapperinterceptor.java:91) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor.proceed(writerinterceptorexecutor.java:162) @ org.glassfish.jersey.message.internal.messagebodyfactory.writeto(messagebodyfactory.java:1154) @ org.glassfish.jersey.server.serverruntime$responder.writeresponse(serverruntime.java:621) @ org.glassfish.jersey.server.serverruntime$responder.processresponse(serverruntime.java:377) @ org.glassfish.jersey.server.serverruntime$responder.process(serverruntime.java:367) @ org.glassfish.jersey.server.serverruntime$1.run(serverruntime.java:274) @ org.glassfish.jersey.internal.errors$1.call(errors.java:271) @ org.glassfish.jersey.internal.errors$1.call(errors.java:267) @ org.glassfish.jersey.internal.errors.process(errors.java:315) @ org.glassfish.jersey.internal.errors.process(errors.java:297) @ org.glassfish.jersey.internal.errors.process(errors.java:267) @ org.glassfish.jersey.process.internal.requestscope.runinscope(requestscope.java:297) @ org.glassfish.jersey.server.serverruntime.process(serverruntime.java:254) @ org.glassfish.jersey.server.applicationhandler.handle(applicationhandler.java:1030) @ org.glassfish.jersey.servlet.webcomponent.service(webcomponent.java:373) @ org.glassfish.jersey.servlet.servletcontainer.service(servletcontainer.java:381) @ org.glassfish.jersey.servlet.servletcontainer.service(servletcontainer.java:344) @ org.glassfish.jersey.servlet.servletcontainer.service(servletcontainer.java:221) @ org.apache.catalina.core.applicationfilterchain.internaldofilter(applicationfilterchain.java:305) @ org.apache.catalina.core.applicationfilterchain.dofilter(applicationfilterchain.java:210) @ org.apache.tomcat.websocket.server.wsfilter.dofilter(wsfilter.java:52) @ org.apache.catalina.core.applicationfilterchain.internaldofilter(applicationfilterchain.java:243) @ org.apache.catalina.core.applicationfilterchain.dofilter(applicationfilterchain.java:210) @ org.apache.catalina.core.standardwrappervalve.invoke(standardwrappervalve.java:222) @ org.apache.catalina.core.standardcontextvalve.invoke(standardcontextvalve.java:123) @ org.apache.catalina.authenticator.authenticatorbase.invoke(authenticatorbase.java:502) @ org.apache.catalina.core.standardhostvalve.invoke(standardhostvalve.java:171) @ org.apache.catalina.valves.errorreportvalve.invoke(errorreportvalve.java:100) @ org.apache.catalina.valves.accesslogvalve.invoke(accesslogvalve.java:953) @ org.apache.catalina.core.standardenginevalve.invoke(standardenginevalve.java:118) @ org.apache.catalina.connector.coyoteadapter.service(coyoteadapter.java:409) @ org.apache.coyote.http11.abstracthttp11processor.process(abstracthttp11processor.java:1044) @ org.apache.coyote.abstractprotocol$abstractconnectionhandler.process(abstractprotocol.java:607) @ org.apache.tomcat.util.net.aprendpoint$socketprocessor.dorun(aprendpoint.java:2441) @ org.apache.tomcat.util.net.aprendpoint$socketprocessor.run(aprendpoint.java:2430) @ java.util.concurrent.threadpoolexecutor.runworker(unknown source) @ java.util.concurrent.threadpoolexecutor$worker.run(unknown source) @ java.lang.thread.run(unknown source) caused by: clientabortexception: java.io.ioexception @ org.apache.catalina.connector.outputbuffer.realwritebytes(outputbuffer.java:413) @ org.apache.tomcat.util.buf.bytechunk.flushbuffer(bytechunk.java:480) @ org.apache.tomcat.util.buf.bytechunk.append(bytechunk.java:366) @ org.apache.catalina.connector.outputbuffer.writebytes(outputbuffer.java:438) @ org.apache.catalina.connector.outputbuffer.write(outputbuffer.java:426) @ org.apache.catalina.connector.coyoteoutputstream.write(coyoteoutputstream.java:91) @ org.glassfish.jersey.servlet.internal.responsewriter$noncloseableoutputstreamwrapper.write(responsewriter.java:298) @ org.glassfish.jersey.message.internal.committingoutputstream.write(committingoutputstream.java:229) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor$uncloseableoutputstream.write(writerinterceptorexecutor.java:299) @ com.fasterxml.jackson.core.json.utf8jsongenerator._flushbuffer(utf8jsongenerator.java:1862) @ com.fasterxml.jackson.core.json.utf8jsongenerator.close(utf8jsongenerator.java:1087) @ com.fasterxml.jackson.jaxrs.base.providerbase.writeto(providerbase.java:637) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor$terminalwriterinterceptor.invokewriteto(writerinterceptorexecutor.java:265) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor$terminalwriterinterceptor.aroundwriteto(writerinterceptorexecutor.java:250) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor.proceed(writerinterceptorexecutor.java:162) @ org.glassfish.jersey.server.internal.jsonwithpaddinginterceptor.aroundwriteto(jsonwithpaddinginterceptor.java:106) @ org.glassfish.jersey.message.internal.writerinterceptorexecutor.proceed(writerinterceptorexecutor.java:162) @ org.glassfish.jersey.server.internal.mappableexceptionwrapperinterceptor.aroundwriteto(mappableexceptionwrapperinterceptor.java:85) ... 38 more caused by: java.io.ioexception @ org.apache.coyote.http11.internalaproutputbuffer.flushbuffer(internalaproutputbuffer.java:205) @ org.apache.coyote.http11.internalaproutputbuffer.access$100(internalaproutputbuffer.java:37) @ org.apache.coyote.http11.internalaproutputbuffer$socketoutputbuffer.dowrite(internalaproutputbuffer.java:235) @ org.apache.coyote.http11.filters.chunkedoutputfilter.dowrite(chunkedoutputfilter.java:117) @ org.apache.coyote.http11.abstractoutputbuffer.dowrite(abstractoutputbuffer.java:192) @ org.apache.coyote.response.dowrite(response.java:517) @ org.apache.catalina.connector.outputbuffer.realwritebytes(outputbuffer.java:408) ... 55 more
i'm using bailiwick of jersey exceptionmapper map several exceptions neither work for
org.glassfish.jersey.server.internal.process.mappableexception
nor for
org.apache.catalina.connector.clientabortexception
is there way grab exception , prevent printing whole stack trace?
edit:
still looking answer...
java rest jersey-2.0
No comments:
Post a Comment