[ 
https://issues.apache.org/jira/browse/CXF-1639?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Bharath Ganesh resolved CXF-1639.
---------------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.7
                   2.1.1

http://www.nabble.com/Memory-Leak-at-WSDLManagerImpl-td17579537.html

Fixing this by always putting a URL as key in this map. The only valid
usage I saw was from WSDLServiceFactory. The WSDLServiceFactory, instead of
using the  wsdlManager.getDefinition(String) method, can create a URL from
this String, strongly refer the URL from wsdlURL field, and invoke the
wsdlManager.getDefinition(URL) method. 

> Memory leak due to literal keys in WSDLDefinition map
> -----------------------------------------------------
>
>                 Key: CXF-1639
>                 URL: https://issues.apache.org/jira/browse/CXF-1639
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.1, 2.0.6
>            Reporter: Bharath Ganesh
>            Assignee: Bharath Ganesh
>             Fix For: 2.1.1, 2.0.7
>
>
> The definitionsMap in WSDLManagerImpl holds the WSDLDefinitions against a 
> weak key, again relying
> on the WeakHashMap semantics for removal.
> The loadDefinition(String) method loads the WSDLDef and puts this in a map
> against a String key. But this String key, is a literal String and will be
> present in the constant pool, where garbage collection never happens. This
> would mean the key would always be referenced from the constant pool, and
> the entry would never be removed.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to