As a maintainer of native node add-on modules I have some questions about when and why NODE_MODULE_VERSION
changes:
(@rvagg has anwered these in the comments below)
- does v8 use semver? how do you know when a v8 version breaks ABI compatibilility?
- is there a semantic meaning for v8 version numbers or is it arbitrary?
- who maintains this google doc I found? is it official?
- why is the latest entry from may in the v8 changelog? https://chromium.googlesource.com/v8/v8.git/+/master/ChangeLog
- how can you tell when all these future v8 versions will be stable? https://chromium.googlesource.com/v8/v8.git/+refs
- why must a node major version correspond to a specific v8 version? e.g. node v5 uses v8 4.6 and won't upgrade to 4.7
- follow-up from last question: assuming v8 4.6 and 4.7 are ABI compatible (according to above google doc), why can't node v5 minor versions use v8 4.7?
- will a new breaking change in v8 always correspond to a new major version of node?
- if a major version of node gets released, and the next week a new stable version of v8 gets released with breaking ABI changes, will node users have to wait 6 months for a stable release with the new v8?
- are there any other reasons besides v8 upgrades that cause
NODE_MODULE_VERSION
to increase?
Yes, in the past there have been core C++ API/ABI changes, a recent example is the
Buffer
changes but that was forced by V8.But, we are now restricting
NODE_MODULE_VERSION
to only be incremented in line with semver-major bumps, so it'll be stable for 6 months and even longer on LTS releases. So every semver-major is held up in the core repo until the next major and we avoid shipping anything that would force aNODE_MODULE_VERSION
bump in between.