FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

src: restrict unloading addons to Worker threads by addaleax · Pull Request #25577 · nodejs/node · GitHub

/ node Public

src: restrict unloading addons to Worker threads - #25577

Closed
addaleax wants to merge 2 commits into
nodejs:masterfrom
addaleax:addon-unload-main-thread
Closed

src: restrict unloading addons to Worker threads#25577
addaleax wants to merge 2 commits into
nodejs:masterfrom
addaleax:addon-unload-main-thread

Conversation

Copy link
Copy Markdown
Member

Unloading native addons from the main thread was an (presumably
unintended) significant breaking change, because addons may
rely on their memory being available after an Environment exits.

This patch only restricts this to Worker threads, at least for the
time being, and thus matches the behaviour from #23319.

Refs: #24861
Refs: #23319

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines

Copy link
Copy Markdown
Collaborator

nodejs-github-bot added the c++ Issues and PRs that require attention from people who are familiar with C++. label Jan 18, 2019
addaleax added the addons Issues and PRs related to native addons. label Jan 18, 2019

addaleax commented Jan 18, 2019
edited
Loading

Copy link
Copy Markdown
Member Author

CI: https://ci.nodejs.org/job/node-test-pull-request/20205/ (:heavy_check_mark:)

Please 👍 this comment to approve fast-tracking – it fixes a regression in 11.7.0.

/cc @MylesBorins @BridgeAR

addaleax added the fast-track PRs that do not need to wait for 48 hours to land. label Jan 18, 2019
addaleax removed the fast-track PRs that do not need to wait for 48 hours to land. label Jan 21, 2019

Copy link
Copy Markdown
Member Author

This needs a second review. (/cc @nodejs/workers maybe?)

refack previously approved these changes Jan 21, 2019
refack dismissed their stale review January 21, 2019 17:46

Code LGTM, but I don't feel knowledgeable enough in this area.

Comment thread src/env.cc Outdated
Comment thread test/addons/worker-addon/binding.cc Outdated
Unloading native addons from the main thread was an (presumably
unintended) significant breaking change, because addons may
rely on their memory being available after an `Environment` exits.

This patch only restricts this to Worker threads, at least for the
time being, and thus matches the behaviour from
nodejs#23319.

Refs: nodejs#24861
Refs: nodejs#23319
addaleax force-pushed the addon-unload-main-thread branch from a6186f8 to d7d409a Compare January 22, 2019 22:16

Copy link
Copy Markdown
Member Author

addaleax added the author ready PRs that have at least one approval, no outstanding review comments, and a CI started. label Jan 22, 2019

addaleax commented Jan 23, 2019
edited by danbev
Loading

Copy link
Copy Markdown
Member Author

Windows failure looks weird.

Rebuild: https://ci.nodejs.org/job/node-test-commit-windows-fanned/24153/ (✔️ )

danbev commented Jan 23, 2019

Copy link
Copy Markdown
Contributor

Landed in ef1c639.

danbev closed this Jan 23, 2019
danbev pushed a commit that referenced this pull request Jan 23, 2019
Unloading native addons from the main thread was an (presumably
unintended) significant breaking change, because addons may
rely on their memory being available after an `Environment` exits.

This patch only restricts this to Worker threads, at least for the
time being, and thus matches the behaviour from
#23319.

PR-URL: #25577
Refs: #24861
Refs: #23319
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
addaleax deleted the addon-unload-main-thread branch January 23, 2019 16:05
addaleax added a commit that referenced this pull request Jan 23, 2019
Unloading native addons from the main thread was an (presumably
unintended) significant breaking change, because addons may
rely on their memory being available after an `Environment` exits.

This patch only restricts this to Worker threads, at least for the
time being, and thus matches the behaviour from
#23319.

PR-URL: #25577
Refs: #24861
Refs: #23319
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
MylesBorins mentioned this pull request Jan 24, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

addons Issues and PRs related to native addons. author ready PRs that have at least one approval, no outstanding review comments, and a CI started. c++ Issues and PRs that require attention from people who are familiar with C++.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants


Back | FazBrowse Home | New Git URL