Skip to content

Possible memory leak in node v4.2.3 #4347

Description

@hybrist

There's an interesting possible problem when upgrading from node 0.10 to node 4: It seems like running code via vm.runInNewContext retains the whole context, including all native constructors, globals, etc.. From our current testing it looks like those are never collected even after nothing in our app code holds a reference to any object belonging to the context, leading to the process running out of memory eventually. After we stopped using vm.runInNewContext, the problem went away.

As mentioned above, we have only circumstantial evidence that the leak is in vm.runInNewContext itself.

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateIssues and PRs that are duplicates of other issues or PRs.memoryIssues and PRs related to Node.js memory management or memory footprint.vmIssues and PRs related to the vm subsystem.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions