Return-Path: X-Original-To: apmail-cxf-users-archive@www.apache.org Delivered-To: apmail-cxf-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C349B18572 for ; Mon, 11 Jan 2016 15:55:32 +0000 (UTC) Received: (qmail 39025 invoked by uid 500); 11 Jan 2016 15:55:31 -0000 Delivered-To: apmail-cxf-users-archive@cxf.apache.org Received: (qmail 38956 invoked by uid 500); 11 Jan 2016 15:55:31 -0000 Mailing-List: contact users-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cxf.apache.org Delivered-To: mailing list users@cxf.apache.org Received: (qmail 38944 invoked by uid 99); 11 Jan 2016 15:55:31 -0000 Received: from Unknown (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Jan 2016 15:55:31 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 0A5F1C04A1 for ; Mon, 11 Jan 2016 15:55:31 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.1 X-Spam-Level: X-Spam-Status: No, score=-0.1 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id JsZFYQp_Qxym for ; Mon, 11 Jan 2016 15:55:21 +0000 (UTC) Received: from mail-wm0-f45.google.com (mail-wm0-f45.google.com [74.125.82.45]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id 567BE20CCD for ; Mon, 11 Jan 2016 15:55:20 +0000 (UTC) Received: by mail-wm0-f45.google.com with SMTP id u188so220099629wmu.1 for ; Mon, 11 Jan 2016 07:55:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-type:content-transfer-encoding; bh=E83OJKqSuZ5pN1c/mbtLg5sG+RoBMrndBAu8SSaDKEA=; b=NhTYr1vKQqd3THp85Xfclbv3BodV0Abvi5wBZc3zN8Kl7dvf/UyGTCxl8oQq0gTwAL VD8PnAXb/P5KwXMnqtUYfhmjXZ05EF4nsLTSTTm3FF9ObborN+BR/YPYNk/XIRuX4VVN QSGtQci2KHGulwUXcsJjNNKa8A7mSLRmhAhX59/940IHSbdgvIPOyBXOar1HMWOIc0vA snncoKXZMCg8C+kZI+3+nCSncpRt2W1ggQSd/mdItZyYnMlQtfVE87ruDrVU0GTiWbiB OQfC1V5LvmqRWqLf8cUkmtBTLjt9Bq0dCk9SsSLHkvSIsSC6NX4GuVk9nnT8EW9Omrvo 0Utw== X-Received: by 10.28.68.214 with SMTP id r205mr15143743wma.23.1452527718927; Mon, 11 Jan 2016 07:55:18 -0800 (PST) Received: from [10.36.226.98] ([80.169.137.63]) by smtp.googlemail.com with ESMTPSA id cv10sm69767464wjb.17.2016.01.11.07.55.17 for (version=TLSv1/SSLv3 cipher=OTHER); Mon, 11 Jan 2016 07:55:18 -0800 (PST) Subject: Re: org.apache.cxf.interceptor.Fault: DISPATCHED,initial To: users@cxf.apache.org References: <003e01d147d8$eef3fb10$ccdbf130$@imed24.pl> <569397DB.7060404@gmail.com> <003001d14c7f$417d66f0$c47834d0$@imed24.pl> From: Sergey Beryozkin Message-ID: <5693D065.2050605@gmail.com> Date: Mon, 11 Jan 2016 15:55:17 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: <003001d14c7f$417d66f0$c47834d0$@imed24.pl> Content-Type: text/plain; charset=iso-8859-2; format=flowed Content-Transfer-Encoding: 8bit Hi �ukasz CXF-5566 seems to be a different issue (and we did not get back to the bottom of why IllegalStateException was thrown in some cases - my only suspicion was that it was related to Jetty versions or possibly something else possibly due to some Camel CXFRS dependencies). The properties can be set in jaxrs:server/jaxrs:properties in Blueprint/Spring. You refer to workarounds, but I'm not sure what the issue is. Can it be that the third-party client you are using is closing the connections too early ? That would explain it - given that you can not reproduce the issue with SoapUI or CXF RS client code Cheers, Sergey On 11/01/16 14:49, �ukasz Bia�y wrote: > Hi Sergey, > > I'm not updating the objects from my application while responding. I'm > rather returning a list of objects almost directly from my database. But I > can try to do some synchronization to check if it helps. > > I saw that there is already an issue reported for this problem: > https://issues.apache.org/jira/browse/CXF-5566. > What makes me wonder is that I cannot reproduce this error when the server > is running on a windows environment. > On linux it is relatively easy to reproduce the error with the client > application we're developing, but when I tried to reproduce it with load > tests (SOAPUI or a small piece of code using cxf-rt-rs-client) I does not > occur. > This bug occurs when running on open-JDK as well as on the Oracle JDK. > > In one comment in jira you mention the setting > "org.apache.cxf.transport.http_jetty.continuations.disable". I didn't > understand where I can change this setting. Is there a possibility to set > this via blueprint? > > I'm also open to workarounds for this issue. I read somewhere that I could > switch jetty for another http module to avoid this, but I'm not sure if this > would have impact on the performance... > > Greetings > �ukasz Bia�y > > -----Original Message----- > Sent: Monday, January 11, 2016 12:54 PM > To: users@cxf.apache.org > Subject: Re: org.apache.cxf.interceptor.Fault: DISPATCHED,initial > > Hi > > It is difficult to suggest why an array is written OK in some cases but not > in other cases when the concurrency is high, my immediate thought that may > be the application data are being updated concurrently too which has some > side-effects on the write process > > Cheers, Sergey > On 05/01/16 16:48, �ukasz Bia�y wrote: >> Hi, >> >> Hopefully this is the right mailing list. >> >> >> >> I am having some trouble with CXF inside Karaf. >> >> >> Sometimes, when the same REST is invoked concurrently at the same >> moment I see the following exception in my log files: >> >> >> >> 2016-01-05 17:11:27,077 | ERROR | qtp1283154258-55 | JAXRSUtils >> | 165 - org.apache.cxf.cxf-rt-frontend-jaxrs - 3.0.7 | Problem with >> | writing >> the data, class java.util.ArrayList, ContentType: application/json >> >> 2016-01-05 17:11:27,082 | WARN | qtp1283154258-55 | >> PhaseInterceptorChain >> | 148 - org.apache.cxf.cxf-core - 3.0.7 | Interceptor for >> {http://my.app/}MyRestEndpointImpl has thrown exception, unwinding now >> >> org.apache.cxf.interceptor.Fault: DISPATCHED,initial >> >> at >> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleWriteExcept >> ion(JA >> XRSOutInterceptor.java:382)[165:org.apache.cxf.cxf-rt-frontend-jaxrs:3 >> .0.7] >> >> at >> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage( >> JAXRSO >> utInterceptor.java:257)[165:org.apache.cxf.cxf-rt-frontend-jaxrs:3.0.7 >> ] >> >> at >> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(J >> AXRSOu >> tInterceptor.java:118)[165:org.apache.cxf.cxf-rt-frontend-jaxrs:3.0.7] >> >> at >> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAX >> RSOutI >> nterceptor.java:81)[165:org.apache.cxf.cxf-rt-frontend-jaxrs:3.0.7] >> >> at >> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto >> rChain .java:307)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outg >> oingCh ainInterceptor.java:83)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto >> rChain .java:307)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitia >> tionOb server.java:121)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractH >> TTPDes >> tination.java:251)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> org.apache.cxf.transport.servlet.ServletController.invokeDestination(S >> ervlet >> Controller.java:234)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> > org.apache.cxf.transport.servlet.ServletController.invoke(ServletController. >> java:208)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> > org.apache.cxf.transport.servlet.ServletController.invoke(ServletController. >> java:160)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpri >> ngServ let.java:180)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(Abs >> tractH >> TTPServlet.java:293)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> org.apache.cxf.transport.servlet.AbstractHTTPServlet.doGet(AbstractHTT >> PServl et.java:217)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> javax.servlet.http.HttpServlet.service(HttpServlet.java:575)[75:org.ap >> ache.g eronimo.specs.geronimo-servlet_3.0_spec:1.0.0] >> >> at >> org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractH >> TTPSer vlet.java:268)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7] >> >> at >> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:684) >> [79:or g.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java: >> 503)[7 >> 9:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doH >> andle( >> HttpServiceServletHandler.java:69)[88:org.ops4j.pax.web.pax-web-jetty: >> 3.2.2] >> >> at >> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja >> va:137 >> )[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java >> :557)[ >> 79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandle >> r.java >> :231)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903 >> ] >> >> at >> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandle >> r.java >> :1086)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v2014090 >> 3] >> >> at >> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(H >> ttpSer viceContext.java:240)[88:org.ops4j.pax.web.pax-web-jetty:3.2.2] >> >> at >> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:4 >> 29)[79 :org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> > org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java: >> 193)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> > org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java: >> 1020)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903 >> ] >> >> at >> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.ja >> va:135 >> )[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection. >> handle >> > (JettyServerHandlerCollection.java:75)[88:org.ops4j.pax.web.pax-web-jetty:3. >> 2.2] >> >> at >> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper. >> java:1 >> 16)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.Server.handle(Server.java:370)[79:org.eclipse >> .jetty .aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(Abstract >> HttpCo >> nnection.java:494)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1 >> .16.v2 >> 0140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(Abstrac >> tHttpC >> onnection.java:971)[79:org.eclipse.jetty.aggregate.jetty-all-server:8. >> 1.16.v >> 20140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerC >> omplet >> e(AbstractHttpConnection.java:1033)[79:org.eclipse.jetty.aggregate.jet >> ty-all >> -server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:644)[79:or >> g.ecli pse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)[ >> 79:org .eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnectio >> n.java >> :82)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> > org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint. >> java:696)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v2014 >> 0903] >> >> at >> org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndP >> oint.j >> ava:53)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v201409 >> 03] >> >> at >> > org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java: >> 608)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool. >> java:5 >> 43)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at java.lang.Thread.run(Thread.java:745)[:1.7.0_79] >> >> Caused by: java.lang.IllegalStateException: DISPATCHED,initial >> >> at >> org.eclipse.jetty.server.AsyncContinuation.handling(AsyncContinuation. >> java:3 >> 37)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(Abstract >> HttpCo >> nnection.java:452)[79:org.eclipse.jetty.aggregate.jetty-all-server:8.1 >> .16.v2 >> 0140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(Abstrac >> tHttpC >> onnection.java:971)[79:org.eclipse.jetty.aggregate.jetty-all-server:8. >> 1.16.v >> 20140903] >> >> at >> org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerC >> omplet >> e(AbstractHttpConnection.java:1033)[79:org.eclipse.jetty.aggregate.jet >> ty-all >> -server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:644)[79:or >> g.ecli pse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.http.HttpParser.available(HttpParser.java:1234)[79:o >> rg.ecl ipse.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.eclipse.jetty.server.HttpInput.available(HttpInput.java:73)[79:org >> .eclip se.jetty.aggregate.jetty-all-server:8.1.16.v20140903] >> >> at >> org.apache.cxf.helpers.IOUtils.copy(IOUtils.java:183)[148:org.apache.c >> xf.cxf >> -core:3.0.7] >> >> at >> org.apache.cxf.helpers.IOUtils.copy(IOUtils.java:142)[148:org.apache.c >> xf.cxf >> -core:3.0.7] >> >> at >> org.apache.cxf.io.DelegatingInputStream.cacheInput(DelegatingInputStre >> am.jav a:54)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination$1.cacheInput(Abs >> tractH >> TTPDestination.java:308)[158:org.apache.cxf.cxf-rt-transports-http:3.0 >> .7] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination.cacheInput(Abstr >> actHTT >> PDestination.java:582)[158:org.apache.cxf.cxf-rt-transports-http:3.0.7 >> ] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination.flushHeaders(Abs >> tractH >> TTPDestination.java:604)[158:org.apache.cxf.cxf-rt-transports-http:3.0 >> .7] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination.flushHeaders(Abs >> tractH >> TTPDestination.java:597)[158:org.apache.cxf.cxf-rt-transports-http:3.0 >> .7] >> >> at >> org.apache.cxf.transport.http.AbstractHTTPDestination$WrappedOutputStr >> eam.on >> FirstWrite(AbstractHTTPDestination.java:775)[158:org.apache.cxf.cxf-rt >> -trans >> ports-http:3.0.7] >> >> at >> org.apache.cxf.io.AbstractWrappedOutputStream.write(AbstractWrappedOut >> putStr eam.java:47)[148:org.apache.cxf.cxf-core:3.0.7] >> >> at >> org.codehaus.jackson.impl.Utf8Generator._flushBuffer(Utf8Generator.jav >> a:1754 >> )[209:jackson-core-asl:1.9.5] >> >> at >> org.codehaus.jackson.impl.Utf8Generator.flush(Utf8Generator.java:1088) >> [209:j >> ackson-core-asl:1.9.5] >> >> at >> org.codehaus.jackson.map.ObjectMapper.writeValue(ObjectMapper.java:161 >> 5)[210 >> :jackson-mapper-asl:1.9.5] >> >> at >> org.codehaus.jackson.jaxrs.JacksonJsonProvider.writeTo(JacksonJsonProv >> ider.j >> ava:558)[211:jackson-jaxrs:1.9.5] >> >> at >> org.apache.cxf.jaxrs.utils.JAXRSUtils.writeMessageBody(JAXRSUtils.java >> :1381) [165:org.apache.cxf.cxf-rt-frontend-jaxrs:3.0.7] >> >> at >> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage( >> JAXRSO >> utInterceptor.java:235)[165:org.apache.cxf.cxf-rt-frontend-jaxrs:3.0.7 >> ] >> >> ... 41 more >> >> >> >> The next REST invocation after this exception gets a random response, >> from an unrelated REST method. Also there are timeouts when invoking >> REST methods. >> I would really appreciate some help with this issue, as aim out of >> ideas on this one. >> >> >> Greetings >> >> Lukasz Bialy >> >> > > > -- > Sergey Beryozkin > > Talend Community Coders > http://coders.talend.com/ > -- Sergey Beryozkin Talend Community Coders http://coders.talend.com/