The Wire · Showcase
NODE CORE LANDS PERFORMANCE WINS ACROSS NET, FS, AND STREAMS
By RepoJournal · Filed · About Node.js
BlockList gets a comprehensive performance overhaul, Windows file handles gain native support, and stream abort logic finally passes spec.
James Snell shipped a sweeping optimization to net.BlockList [1] that eliminates shared pointers, adds read/write locking, introduces bulk address operations, and includes a new clear method, addressing both correctness and speed across the entire API. Windows developers now have a path forward: a new windowsHandle option on fs.createReadStream() and fs.createWriteStream() [2] wraps raw Win32 HANDLEs through CRT file descriptors, fixing the EBADF failures that plagued inherited pipe handles from other processes. The streams implementation fixed a critical recursive abort bug [3] by rechecking stream state after signaling abort, as the spec requires, finally passing WPT and removing its expected-failure entry. Separately, zlib tightened ZIP parsing by rejecting ambiguous EOCD records [4], scanning candidates in a consistent tail window to prevent trailing padding from changing which central directory gets used. Buffer allocation gains optional alignment support [5], letting you allocate 4096-byte aligned buffers for direct file I/O without wrapper overhead. On the infrastructure side, docker-node switched to consuming dist/index.json for version resolution [6], simplifying the release pipeline and removing HTML parsing fragility [7].
One email a day. Unsubscribe in one click.
Keep up with Node.js in about 3 minutes a day: what actually shipped — the commits, pull requests, releases, and security advisories that matter.
One email a day. Unsubscribe in one click. Read a past issue →
Action items
- → Review net.BlockList usage in production for lock contention opportunities from the new read/write locking nodejs/node [plan]
- → Test fs.createReadStream with windowsHandle option if you inherit pipes from other processes on Windows nodejs/node [plan]
- → Verify ZIP file handling in your zlib code paths with padded archives nodejs/node [monitor]
References
- [1] net: improve performance of net.BlockList nodejs/node
- [2] fs: add windowsHandle option to file streams ↗ nodejs/node
- [3] stream: fix recursive WritableStream abort nodejs/node
- [4] zlib: reject ambiguous ZIP archive ends ↗ nodejs/node
- [5] buffer: support aligned allocations ↗ nodejs/node
- [6] chore: consume dist/index.json when resolving versions ↗ nodejs/docker-node
- [7] chore: consume dist/index.json when resolving versions (#2598) nodejs/docker-node