You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Ivan (JIRA)" <ji...@apache.org> on 2012/09/27 16:04:07 UTC
[jira] [Created] (CXF-4523) Unclosed XMLStreamReader/Writer causes
leaking
Ivan created CXF-4523:
-------------------------
Summary: Unclosed XMLStreamReader/Writer causes leaking
Key: CXF-4523
URL: https://issues.apache.org/jira/browse/CXF-4523
Project: CXF
Issue Type: Bug
Affects Versions: 2.6.2
Reporter: Ivan
I created some wrapper classes for those XMLStreamReader created in StaxUtils, and found that the one created with the stack below will not invoke the close() method, which will cause some leaking
ava.lang.Throwable
at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:136)
at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1280)
at org.apache.cxf.interceptor.StaxInInterceptor.handleMessage(StaxInInterceptor.java:111)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:262)
at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
......
java.lang.Throwable
at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:169)
at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1363)
at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1247)
at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:231)
at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:191)
......
http://cxf.547215.n5.nabble.com/XMLStreamReader-is-never-closed-td5714822.html
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (CXF-4523) Unclosed XMLStreamReader/Writer causes
leaking
Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/CXF-4523?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Daniel Kulp updated CXF-4523:
-----------------------------
Fix Version/s: 2.6.3
2.5.6
> Unclosed XMLStreamReader/Writer causes leaking
> ----------------------------------------------
>
> Key: CXF-4523
> URL: https://issues.apache.org/jira/browse/CXF-4523
> Project: CXF
> Issue Type: Bug
> Affects Versions: 2.6.2
> Reporter: Ivan
> Fix For: 2.5.6, 2.6.3
>
> Attachments: CXF-4523.patch
>
>
> I created some wrapper classes for those XMLStreamReader created in StaxUtils, and found that the one created with the stack below will not invoke the close() method, which will cause some leaking
> ava.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:136)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1280)
> at org.apache.cxf.interceptor.StaxInInterceptor.handleMessage(StaxInInterceptor.java:111)
> at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:262)
> at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
> ......
> java.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:169)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1363)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1247)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:231)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:191)
> ......
> http://cxf.547215.n5.nabble.com/XMLStreamReader-is-never-closed-td5714822.html
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (CXF-4523) Unclosed XMLStreamReader/Writer causes
leaking
Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/CXF-4523?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Daniel Kulp resolved CXF-4523.
------------------------------
Resolution: Fixed
Assignee: Daniel Kulp
Slightly modified patch applied. Had to hack around some issues in the JAX-RS frontend that will need to be refactored later.
> Unclosed XMLStreamReader/Writer causes leaking
> ----------------------------------------------
>
> Key: CXF-4523
> URL: https://issues.apache.org/jira/browse/CXF-4523
> Project: CXF
> Issue Type: Bug
> Affects Versions: 2.6.2
> Reporter: Ivan
> Assignee: Daniel Kulp
> Fix For: 2.5.6, 2.6.3
>
> Attachments: CXF-4523.patch
>
>
> I created some wrapper classes for those XMLStreamReader created in StaxUtils, and found that the one created with the stack below will not invoke the close() method, which will cause some leaking
> ava.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:136)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1280)
> at org.apache.cxf.interceptor.StaxInInterceptor.handleMessage(StaxInInterceptor.java:111)
> at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:262)
> at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
> ......
> java.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:169)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1363)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1247)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:231)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:191)
> ......
> http://cxf.547215.n5.nabble.com/XMLStreamReader-is-never-closed-td5714822.html
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (CXF-4523) Unclosed XMLStreamReader/Writer causes
leaking
Posted by "Ivan (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/CXF-4523?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ivan updated CXF-4523:
----------------------
Attachment: CXF-4523.patch
Create a patch file based on Daniel's suggestion, two interceptors are created for close the created reader.
I am not quite sure about the PHASE, now I use the POST_INVOKE.
> Unclosed XMLStreamReader/Writer causes leaking
> ----------------------------------------------
>
> Key: CXF-4523
> URL: https://issues.apache.org/jira/browse/CXF-4523
> Project: CXF
> Issue Type: Bug
> Affects Versions: 2.6.2
> Reporter: Ivan
> Attachments: CXF-4523.patch
>
>
> I created some wrapper classes for those XMLStreamReader created in StaxUtils, and found that the one created with the stack below will not invoke the close() method, which will cause some leaking
> ava.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:136)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1280)
> at org.apache.cxf.interceptor.StaxInInterceptor.handleMessage(StaxInInterceptor.java:111)
> at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:262)
> at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
> ......
> java.lang.Throwable
> at org.apache.cxf.staxutils.XXMLStreamReader.<init>(XXMLStreamReader.java:29)
> at org.apache.cxf.staxutils.XXMLInputFactory.createXMLStreamReader(XXMLInputFactory.java:169)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1363)
> at org.apache.cxf.staxutils.StaxUtils.createXMLStreamReader(StaxUtils.java:1247)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:231)
> at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:191)
> ......
> http://cxf.547215.n5.nabble.com/XMLStreamReader-is-never-closed-td5714822.html
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira