Skip to content

Memory leak for large string attribute values #18

@chrisdruta

Description

@chrisdruta

Just a heads up for anyone else - I believe I observed a memory leak from this package. After swapping the library to another (e.g. fast-xml-parser), the problem seems to have gone away.

Believe the leak is coming from the write function in the sax parser, as the other [issue 5] points out its locked to a rather old version.

Repro that expands rather quickly from my testing (harness looping reading the xml string):

  • xml file with not too many tags
  • one of the tags has an attribute that is a super long string (ballpark of 15 - 25mb)
  • has arrays option defined containing above tag

Should see the heap memory go up and up vs others libraries properly freeing when necessary

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions