[ https://issues.apache.org/jira/browse/AXIS2-6030?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17545211#comment-17545211 ]
David Steindorfer edited comment on AXIS2-6030 at 6/2/22 1:09 AM: ------------------------------------------------------------------ Hi [~robertlazarski] Thank you for the reply. In fact our project was configured for HTTP Client 4x since at least 2020. For 1.7.9 and 1.8.0 I use exactly the same configuration as seen here: - https://github.com/dsteindo/Axis2Examples/blob/main/1.7.9/jaxws/resources/axis2/default/conf/axis2.xml - https://github.com/dsteindo/Axis2Examples/blob/main/1.8.0/jaxws/resources/axis2/default/conf/axis2.xml The httpclient libraries are a maven dependency of axis2 I think For 1.7.9 they are - httpclient-4.5.3.jar - httpcore-4.4.6.jar For 1.8.0 they are - httpclient-4.5.13.jar - httpcore-4.4.13.jar I try to remember what I saw when digging (debugging) through the code where I noticed some difference in 1.7.9 and 1.8.0 *1.7.9* Here I see that the connection is released: {code} release:404, AbstractConnPool (org.apache.http.pool) releaseConnection:272, PoolingClientConnectionManager (org.apache.http.impl.conn) releaseConnection:472, ManagedClientConnectionImpl (org.apache.http.impl.conn) releaseManagedConnection:204, BasicManagedEntity (org.apache.http.conn) eofDetected:152, BasicManagedEntity (org.apache.http.conn) checkEOF:199, EofSensorInputStream (org.apache.http.conn) read:136, EofSensorInputStream (org.apache.http.conn) read:48, DetachableInputStream (org.apache.axiom.om.impl.common.factory) readBytes:155, BaseReader (com.ctc.wstx.io) loadMore:369, UTF8Reader (com.ctc.wstx.io) read:116, UTF8Reader (com.ctc.wstx.io) read:104, MergedReader (com.ctc.wstx.io) readInto:88, ReaderSource (com.ctc.wstx.io) readInto:57, BranchingReaderSource (com.ctc.wstx.io) loadMore:1011, StreamScanner (com.ctc.wstx.sr) getNext:770, StreamScanner (com.ctc.wstx.sr) nextFromProlog:2096, BasicStreamReader (com.ctc.wstx.sr) closeContentTree:3000, BasicStreamReader (com.ctc.wstx.sr) nextFromTree:2748, BasicStreamReader (com.ctc.wstx.sr) next:1122, BasicStreamReader (com.ctc.wstx.sr) next:225, XMLStreamReaderWrapper (org.apache.axiom.util.stax.wrapper) next:34, DisallowDoctypeDeclStreamReaderWrapper (org.apache.axiom.util.stax.dialect) parserNext:666, StAXOMBuilder (org.apache.axiom.om.impl.builder) next:184, StAXOMBuilder (org.apache.axiom.om.impl.builder) _getBlockFromOMElement:631, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:348, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:521, XMLPartBase (org.apache.axis2.jaxws.message.impl) getBodyBlock:668, MessageImpl (org.apache.axis2.jaxws.message.impl) getReturnElement:724, MethodMarshallerUtils (org.apache.axis2.jaxws.marshaller.impl.alt) demarshalResponse:121, DocLitBareMethodMarshaller (org.apache.axis2.jaxws.marshaller.impl.alt) createResponse:546, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invokeSEIMethod:386, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invoke:171, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) pingOperation:-1, $Proxy62 (com.sun.proxy) ping:54, PingTest (at.dsteindo.axis2.execute) execute:18, PingTest (at.dsteindo.axis2.execute) main:18, Registry (at.dsteindo.axis2.core) {code} *1.8.0* It goes a somewhat different path and I can go until org.apache.axis2.jaxws.message.impl.XMLSpineImpl#_getBlockFromOMElement {code} _getBlockFromOMElement:561, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:336, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:520, XMLPartBase (org.apache.axis2.jaxws.message.impl) getBodyBlock:668, MessageImpl (org.apache.axis2.jaxws.message.impl) getReturnElement:724, MethodMarshallerUtils (org.apache.axis2.jaxws.marshaller.impl.alt) demarshalResponse:120, DocLitBareMinimalMethodMarshaller (org.apache.axis2.jaxws.marshaller.impl.alt) createResponse:546, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invokeSEIMethod:386, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invoke:171, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) echoOperation:-1, $Proxy61 (com.sun.proxy) echoOperation:116, EchoServicePortProxy (org.apache.axis2.jaxws.samples.client.echo) echo:62, EchoTest (at.dsteindo.axis2.execute) execute:22, EchoTest (at.dsteindo.axis2.execute) main:20, Registry (at.dsteindo.axis2.core) {code} I was then playing around with the debugger and at some point my IDE notified me that I skipped a breakpoint !screenshot-1.png! Which is most likely the breakpoint I placed inside org.apache.http.impl.conn.PoolingHttpClientConnectionManager#releaseConnection Code {code} om.getParent().getBuilder().detach() {code} Then the next iteration I noticed that I had the connection available !screenshot-2.png! Comparision to when I did not play around while debugging and thus did not cause the preakpoint skipped notification !screenshot-3.png! This might be an possible solution, but I am not sure if it might cause issues with more deeply nested elements ... Also concluded that axis2-jaxws-1.8.0.jar is the affected library, which makes sense for jaxws integration :) Hopefully this can help your team in figuring out a solution (on) was (Author: JIRAUSER287101): Hi [~robertlazarski] Thank you for the reply. In fact our project was configured for HTTP Client 4x since at least 2020. For 1.7.9 and 1.8.0 I use exactly the same configuration as seen here: - https://github.com/dsteindo/Axis2Examples/blob/main/1.7.9/jaxws/resources/axis2/default/conf/axis2.xml - https://github.com/dsteindo/Axis2Examples/blob/main/1.8.0/jaxws/resources/axis2/default/conf/axis2.xml The httpclient libraries are a maven dependency of axis2 I think For 1.7.9 they are - httpclient-4.5.3.jar - httpcore-4.4.6.jar For 1.8.0 they are - httpclient-4.5.13.jar - httpcore-4.4.13.jar I try to remember what I saw when digging (debugging) through the code where I noticed some difference in 1.7.9 and 1.8.0 *1.7.9* Here I see that the connection is released: {code} release:404, AbstractConnPool (org.apache.http.pool) releaseConnection:272, PoolingClientConnectionManager (org.apache.http.impl.conn) releaseConnection:472, ManagedClientConnectionImpl (org.apache.http.impl.conn) releaseManagedConnection:204, BasicManagedEntity (org.apache.http.conn) eofDetected:152, BasicManagedEntity (org.apache.http.conn) checkEOF:199, EofSensorInputStream (org.apache.http.conn) read:136, EofSensorInputStream (org.apache.http.conn) read:48, DetachableInputStream (org.apache.axiom.om.impl.common.factory) readBytes:155, BaseReader (com.ctc.wstx.io) loadMore:369, UTF8Reader (com.ctc.wstx.io) read:116, UTF8Reader (com.ctc.wstx.io) read:104, MergedReader (com.ctc.wstx.io) readInto:88, ReaderSource (com.ctc.wstx.io) readInto:57, BranchingReaderSource (com.ctc.wstx.io) loadMore:1011, StreamScanner (com.ctc.wstx.sr) getNext:770, StreamScanner (com.ctc.wstx.sr) nextFromProlog:2096, BasicStreamReader (com.ctc.wstx.sr) closeContentTree:3000, BasicStreamReader (com.ctc.wstx.sr) nextFromTree:2748, BasicStreamReader (com.ctc.wstx.sr) next:1122, BasicStreamReader (com.ctc.wstx.sr) next:225, XMLStreamReaderWrapper (org.apache.axiom.util.stax.wrapper) next:34, DisallowDoctypeDeclStreamReaderWrapper (org.apache.axiom.util.stax.dialect) parserNext:666, StAXOMBuilder (org.apache.axiom.om.impl.builder) next:184, StAXOMBuilder (org.apache.axiom.om.impl.builder) _getBlockFromOMElement:631, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:348, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:521, XMLPartBase (org.apache.axis2.jaxws.message.impl) getBodyBlock:668, MessageImpl (org.apache.axis2.jaxws.message.impl) getReturnElement:724, MethodMarshallerUtils (org.apache.axis2.jaxws.marshaller.impl.alt) demarshalResponse:121, DocLitBareMethodMarshaller (org.apache.axis2.jaxws.marshaller.impl.alt) createResponse:546, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invokeSEIMethod:386, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invoke:171, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) pingOperation:-1, $Proxy62 (com.sun.proxy) ping:54, PingTest (at.dsteindo.axis2.execute) execute:18, PingTest (at.dsteindo.axis2.execute) main:18, Registry (at.dsteindo.axis2.core) {code} *1.8.0* It goes a somewhat different path and I can go until org.apache.axis2.jaxws.message.impl.XMLSpineImpl#_getBlockFromOMElement {code} _getBlockFromOMElement:561, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:336, XMLSpineImpl (org.apache.axis2.jaxws.message.impl) getBodyBlock:520, XMLPartBase (org.apache.axis2.jaxws.message.impl) getBodyBlock:668, MessageImpl (org.apache.axis2.jaxws.message.impl) getReturnElement:724, MethodMarshallerUtils (org.apache.axis2.jaxws.marshaller.impl.alt) demarshalResponse:120, DocLitBareMinimalMethodMarshaller (org.apache.axis2.jaxws.marshaller.impl.alt) createResponse:546, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invokeSEIMethod:386, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) invoke:171, JAXWSProxyHandler (org.apache.axis2.jaxws.client.proxy) echoOperation:-1, $Proxy61 (com.sun.proxy) echoOperation:116, EchoServicePortProxy (org.apache.axis2.jaxws.samples.client.echo) echo:62, EchoTest (at.dsteindo.axis2.execute) execute:22, EchoTest (at.dsteindo.axis2.execute) main:20, Registry (at.dsteindo.axis2.core) {code} I was then playing around with the debugger and at some point my IDE notified me that I skipped a breakpoint !screenshot-1.png! Which is most likely the breakpoint I placed inside org.apache.http.impl.conn.PoolingHttpClientConnectionManager#releaseConnection Code {code} om.getParent().getBuilder().detach() {code} Then the next iteration I noticed that I had the connection available !screenshot-2.png! Comparision to when I did not play around while debugging and causing the preakpoint skipped notification !screenshot-3.png! This might be an possible solution, but I am not sure if it might cause issues with more deeply nested elements ... Also concluded that axis2-jaxws-1.8.0.jar is the affected library, which makes sense for jaxws integration :) Hopefully this can help your team in figuring out a solution (on) > Axis2 connections are not returned to connection pool on 1.8.0 with JAXWS > ------------------------------------------------------------------------- > > Key: AXIS2-6030 > URL: https://issues.apache.org/jira/browse/AXIS2-6030 > Project: Axis2 > Issue Type: Bug > Components: jaxws > Affects Versions: 1.8.0 > Reporter: David Steindorfer > Assignee: Robert Lazarski > Priority: Major > Attachments: echoTestInterruptionException.txt, screenshot-1.png, > screenshot-2.png, screenshot-3.png > > > Good Afternoon, > > I have upgraded Axis2 from 1.7.9 to 1.8.0 on one of our projects. > However with the upgrade the requests seem to get stuck. > On further analysis I figured out that the connection pool ran dry as the > connections were not returned. > > It took a while to reproduce the issue reliably and isolated from the other > code of our project but under very similar circumstances. > Thus I created a public git repo with the code I wrote to reproduce the issue: > [https://github.com/dsteindo/Axis2Examples] > > I think the affected component is the "axis2-transport-http" library. > For now I reverted the project's libraries back to 1.7.9. > But it would be awesome to use the latest libraries, considering that you did > quite a lot of changes and improvements :) > > Please feel free to contact me if more information is needed, but I guess > that everything should be documented with the git repository. -- This message was sent by Atlassian Jira (v8.20.7#820007) --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscr...@axis.apache.org For additional commands, e-mail: java-dev-h...@axis.apache.org