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

src: set an appropriate thread pool size if given --v8-pool-size=0 #45513

Merged

Conversation

daeyeon
Copy link
Member

@daeyeon daeyeon commented Nov 19, 2022

Node.js doesn't terminate when any pending V8 tasks exist if no thread is in the pool.

This allocates one thread at least for the tasks if --v8-pool-size=0 is given as a CLI option.

Fixes: #42523
Alternative to #42524

Signed-off-by: Daeyeon Jeong daeyeon.dev@gmail.com

It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. needs-ci PRs that need a full CI run. labels Nov 19, 2022
@daeyeon
Copy link
Member Author

daeyeon commented Nov 19, 2022

/cc @nodejs/cpp-reviewers

@anonrig anonrig added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. request-ci Add this label to start a Jenkins CI on a PR. labels Nov 19, 2022
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Nov 19, 2022
@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot
Copy link
Collaborator

…ize=0`

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
@daeyeon daeyeon added request-ci Add this label to start a Jenkins CI on a PR. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Nov 20, 2022
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Nov 20, 2022
@nodejs-github-bot
Copy link
Collaborator

Copy link
Member

@RafaelGSS RafaelGSS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@aduh95 aduh95 added the commit-queue Add this label to land a pull request using GitHub Actions. label Nov 20, 2022
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Nov 21, 2022
@nodejs-github-bot nodejs-github-bot merged commit 47d3adb into nodejs:main Nov 21, 2022
@nodejs-github-bot
Copy link
Collaborator

Landed in 47d3adb

@daeyeon daeyeon deleted the main.thread-pool-221118.Fri.def2 branch November 21, 2022 03:52
ruyadorno pushed a commit that referenced this pull request Nov 21, 2022
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
marco-ippolito pushed a commit to marco-ippolito/node that referenced this pull request Nov 23, 2022
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: nodejs#45513
Fixes: nodejs#42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
@ruyadorno ruyadorno mentioned this pull request Nov 24, 2022
danielleadams pushed a commit that referenced this pull request Dec 30, 2022
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
danielleadams pushed a commit that referenced this pull request Dec 30, 2022
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
danielleadams pushed a commit that referenced this pull request Jan 3, 2023
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
danielleadams pushed a commit that referenced this pull request Jan 4, 2023
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
danielleadams pushed a commit that referenced this pull request Jan 5, 2023
It doesn't terminate when any pending V8 tasks exist if no thread
is in the pool.

This allocates one thread at least for V8's background tasks if
`--v8-pool-size=0` is given as a CLI option.

Signed-off-by: Daeyeon Jeong <daeyeon.dev@gmail.com>
PR-URL: #45513
Fixes: #42523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. c++ Issues and PRs that require attention from people who are familiar with C++. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. needs-ci PRs that need a full CI run.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Run worker threads with --v8-pool-size=0
8 participants