Welcome to this week’s wrap up of the week in Node and libuv covering August 1 through August 7. The purpose of this blog is to recap a subset of the non-documentation related commits to Node.js, plus give a little color and commentary to the ongoing development of Node.
Node.js v0.10 branch highlights
http: improve chunked res.write(buf) performance
crypto: fix assert() on malformed hex input
Ben optimized the HTTP module a little in 3398cce.
res.write(buf) got faster by 50-600% for large buffers (roughly 10 KB and up.) The original bug report and initial patch was by Wyatt Preul of Walmart. Ben took the concept from his patch and applied some more hackery, loop unrolling and manual inlining to make things faster still. This commit fixes #5941 and #5944.
events: fix memory leak, don’t leak event names
Ben reverted an old optimization in the EventEmitter class in fc6f8a6. It was leaking memory because the strings containing the event names were never released. Some modules emit literally millions of different events so all that memory starts to add up. Fixes #5970.
v8: back-port fix for CVE-2013-2882
stream: Fix double pipe error emit
You can view the complete Nodev0.10 commit history on GitHub.
Node.js master branch highlights
node: add inTick and lastThrew to infoBox
src: lint c++ code
Fedor is also rockin’ a mean looking new avatar on GitHub and with 8e29ce9, the C++ section of the Node.js code base gets linted with cpplint. Any changes henceforth should pass
make cpplint. Ben adds that, “VIOLATORS WILL BE PUNISHED! Actually, there were a lot of lint-related commits around that time, some from Fedor, some from me. I just picked the biggest one.”
os: add mac address to networkInterfaces() output
tls_wrap: parse tls session ticket extension
TLS session ticket handling was optimized by Fedor in dda22a5. It no longer calls the user’s resumeSession callback unnecessarily.
build: fix –without-ssl build
Ben fixed the –without-ssl build in e772a7d.
tls: fix handling of
SNICallback server option
Fedor fixed SNICallback handling in ea7b817.
v8: fix openbsd build
Ben fixed the OpenBSD build in 222e523. End of the day, this is really a V8 issue. Ben sent the patch upstream, but we don’t know if it landed yet.
https: fix default port
Koichi Kobayashi fixed a regression in default port handling for HTTPS requests with http.request() in 72ad2c9. When the port was omitted from the request URL, it picked port 80 rather than 443. Ben points out that it’s embarrassing that a bug like that got past our test suite. But all our HTTPS tests bind to non-standard ports because port 443 is not available to non-root users.
build: embed the mdb_v8.so into the binary
tls: asynchronous SNICallback
The TLS SNI callback is asynchronous as of 048e0e7. Useful if, for example, you need to look up the servername in a database. Patch by Fedor.
You can view the complete Node master commit history on GitHub.
libuv v0.10 branch highlights
Check back next week!
You can view the complete libuv v0.10 commit history on GitHub.
libuv master branch highlights
windows: fix mingw32 build, include limits.h
windows: fix mingw32 build, define JOB_OBJECT_XXX
You can view the complete libuv master commit history on GitHub.
- Ready to develop APIs in Node.js and get them connected to your data? Check out the Node.js LoopBack framework. We’ve made it easy to get started either locally or on your favorite cloud, with a simple npm install.