cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Giovanni Borelli (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CXF-6632) Memory leak due to literal keys in WSDLDefinition map
Date Thu, 08 Oct 2015 17:04:27 GMT

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

Giovanni Borelli updated CXF-6632:
----------------------------------
    Description: 
Looks like the definitionsMap in WSDLManagerImpl holds the WSDLDefinitions against a weak
key, again relying
on the WeakHashMap semantics for removal.

The loadDefinition(URL) 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.

  was:
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.


> Memory leak due to literal keys in WSDLDefinition map
> -----------------------------------------------------
>
>                 Key: CXF-6632
>                 URL: https://issues.apache.org/jira/browse/CXF-6632
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.7.17
>            Reporter: Giovanni Borelli
>            Assignee: Bharath Ganesh
>            Priority: Minor
>
> Looks like the definitionsMap in WSDLManagerImpl holds the WSDLDefinitions against a
weak key, again relying
> on the WeakHashMap semantics for removal.
> The loadDefinition(URL) 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 was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message