-
Notifications
You must be signed in to change notification settings - Fork 28.6k
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
lib: improve cluster/primary code #53756
base: main
Are you sure you want to change the base?
Conversation
|
||
if (workers.length === 0) { | ||
process.nextTick(() => intercom.emit('disconnect')); | ||
} else { | ||
for (const worker of ObjectValues(cluster.workers)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nodejs/cluster |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, it may make sense to also address the for of
primordials issue but that code was for..of before so that isn't a regression
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Improved code for lib/cluster/primary: