Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix memory leak in fetch() #6350

Merged
merged 1 commit into from
Oct 7, 2023
Merged

Fix memory leak in fetch() #6350

merged 1 commit into from
Oct 7, 2023

Conversation

Jarred-Sumner
Copy link
Collaborator

What does this PR do?

We were not calling inflateEnd, which caused fetch() requests with gzip/deflate to leak memory

hmasd

How did you verify your code works?

Memory usage is more stable now

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

@Jarred-Sumner prettier reported errors

[warn] test/cli/install/bun-install.test.ts
[warn] Code style issues found in the above file. Forgot to run Prettier?
error: "prettier" exited with code 1 (SIGHUP)
Checking formatting...

To one-off fix this manually, run:

bun fmt

You might need to run bun install locally and configure your text editor to auto-format on save.

#db1963f4f3417cecafa0ffd27a49e6bacca80fb0

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

@Jarred-Sumner 5 files with test failures on linux-x64-baseline:

  • test/cli/install/bun-install.test.ts
  • test/js/node/watch/fs.watch.test.ts
  • test/js/third_party/mongodb/mongodb.test.ts
  • test/js/third_party/postgres/postgres.test.ts
  • test/js/third_party/prisma/prisma.test.ts

View test output

#db1963f4f3417cecafa0ffd27a49e6bacca80fb0

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

@Jarred-Sumner 6 files with test failures on linux-x64:

  • test/cli/install/bun-install.test.ts
  • test/js/node/watch/fs.watch.test.ts
  • test/js/third_party/mongodb/mongodb.test.ts
  • test/js/third_party/postgres/postgres.test.ts
  • test/js/third_party/prisma/prisma.test.ts
  • test/js/web/worker.test.ts

View test output

#db1963f4f3417cecafa0ffd27a49e6bacca80fb0

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

@Jarred-Sumner 10 files with test failures on bun-darwin-aarch64:

  • test/bundler/bundler_edgecase.test.ts
  • test/cli/install/bun-install.test.ts
  • test/integration/next/default-pages-dir/test/dev-server.test.ts
  • test/js/bun/test/test-test.test.ts
  • test/js/bun/util/filesink.test.ts
  • test/js/node/watch/fs.watch.test.ts
  • test/js/third_party/mongodb/mongodb.test.ts
  • test/js/third_party/postgres/postgres.test.ts
  • test/js/third_party/prisma/prisma.test.ts
  • test/js/web/worker.test.ts

View test output

#db1963f4f3417cecafa0ffd27a49e6bacca80fb0

@github-actions
Copy link
Contributor

github-actions bot commented Oct 7, 2023

@Jarred-Sumner 10 files with test failures on bun-darwin-x64-baseline:

  • test/cli/install/bun-install.test.ts
  • test/integration/next/default-pages-dir/test/next-build.test.ts
  • test/js/bun/test/test-test.test.ts
  • test/js/bun/util/filesink.test.ts
  • test/js/node/fs/fs.test.ts
  • test/js/third_party/mongodb/mongodb.test.ts
  • test/js/third_party/postgres/postgres.test.ts
  • test/js/third_party/prisma/prisma.test.ts
  • test/js/third_party/webpack/webpack.test.ts
  • test/js/web/timers/setTimeout.test.js

View test output

#db1963f4f3417cecafa0ffd27a49e6bacca80fb0

@joulev
Copy link

joulev commented Oct 7, 2023

This is amazing. As someone who is using Bun to run a long-running process in production, this is really needed. Props to the team 💯

@Jarred-Sumner Jarred-Sumner merged commit 25cf401 into main Oct 7, 2023
14 of 20 checks passed
@Jarred-Sumner Jarred-Sumner deleted the jarred/fix-mem-leak branch October 7, 2023 03:14
@ralyodio
Copy link

ralyodio commented Oct 9, 2023

good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants