You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by "Michael Glavassevich (Assigned) (JIRA)" <xe...@xml.apache.org> on 2012/03/20 04:41:46 UTC

[jira] [Assigned] (XERCESJ-1430) Memory leak: Elements with id attributes are not garbage collectable if the id attribute is not removed.

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

Michael Glavassevich reassigned XERCESJ-1430:
---------------------------------------------

    Assignee: Michael Glavassevich
    
> Memory leak: Elements with id attributes are not garbage collectable if the id attribute is not removed.
> --------------------------------------------------------------------------------------------------------
>
>                 Key: XERCESJ-1430
>                 URL: https://issues.apache.org/jira/browse/XERCESJ-1430
>             Project: Xerces2-J
>          Issue Type: Bug
>          Components: DOM (Level 3 Core)
>    Affects Versions: 2.9.1
>            Reporter: Ludger Bünger
>            Assignee: Michael Glavassevich
>         Attachments: IdentifiersWeakValuePatch.txt
>
>
> Memoryleak:
> Inside CoreDocumentImpl a HashTable resides that holds an id string to element mapping.
> If an element is removed from the DOM this Map is only updated if one also removes the id attribute.
> Thus the element is not garbage collectable.
> Solution:
> Use an Map implementation that holds only a weak reference to it's values.
> See attached patch

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: j-dev-help@xerces.apache.org