-
Notifications
You must be signed in to change notification settings - Fork 29.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
[WIP] src: introduce node_bootstrap and node_process #20879
Conversation
This continues the reorganization of node.cc by splitting the implementations of most process object functions and properties out to a separate node_process.cc and creates a separate temporary bootstrapper object used during Node.js bootstrap to avoid the need for deleting/overwriting process properties set during bootstrap.
Various cleanups within SetupProcessObject to improve readability
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.
JS changes LGTM.
Rubber stamp LGTM on C++ changes, assuming it's mostly cut and paste.
Big +1 on reducing the number of lines in node.cc
!
Can we do this in smaller chunks, more slowly? Landing a patch this size is going to be a major source of conflicts, and not just with things like #20876… |
Yeah, splitting it up is possible but will take awhile longer. I'd like to get agreement on this path before staring to do that. :) |
@addaleax ... before I start splitting this up, can I ask you to give me a better sense for how it should be split up so the effort will have the least dramatic impact on what you're working on with the Workers stuff. |
Starting to break things up a bit: #20917 |
@jasnell Yes, that smaller PR looks better with regard to conflicts :) In general, the easiest thing to check for how much "conflict potential" there is would be applying on PRs on top of the other… taking it in small chunks is definitely the right approach here |
Furthering the cause of breaking node.cc up into smaller, more manageable chunks.
This does two main things:
Adds a new bootstrapper object that is used only during bootstrap to avoid having to delete and overwrite properties on
process
during bootstrapMoves most of the
process
function and property definitions tonode_process.cc
for better isolation.Functionality is the same, tho there are some code cleanups along the way. This should be semver-patch.
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes