Skip to content

Possible memory leak #48

@aikoven

Description

@aikoven

We noticed a memory leak in our services that use node-foundationdb, which appears to be somewhere in native code, because NodeJS heap size stays at consistent levels, but the total process memory grows.

I made a repro, see https://github.com/aikoven/node-foundationdb-memory-leak-repro

This repro makes simple read-only transactions in a loop:

while (true) {
  await db.doTn(async tn => {
    await tn.get('');
  });
}

After about an hour, the process consumed about 700MB of memory, while NodeJS heap usage was consistently ~90MB.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions