node v0.8 is out and it’s HOT!

Just announced on the node blog: http://blog.nodejs.org/2012/06/25/node-v0-8-0/

This release brings a big boost in performance and stability along with a few other goodies.

My quick summary

1. Major performance increases around I/O operations mainly due to V8 improvements. “The more bytes you’re pushing, and the more work you’re doing, the more win you’ll see with node 0.8 over 0.6.”

Check out these hello world results. Notice the increases are event greater for larger payloads.

$ TYPE=bytes LENGTH=123 bash benchmark/http.sh  2>&1 | grep Req
# 0.6.19
Requests per second:    3317.24 [#/sec] (mean)
# 0.8.0
Requests per second:    3795.34 [#/sec] (mean)


$ TYPE=bytes LENGTH=1024 bash benchmark/http.sh  2>&1 | grep Req
# v0.6.19
Requests per second:    3258.42 [#/sec] (mean)
# 0.8.0
Requests per second:    3585.62 [#/sec] (mean)


$ TYPE=bytes LENGTH=123456 bash benchmark/http.sh  2>&1 | grep Req
# v0.6.19
Requests per second:    218.51 [#/sec] (mean)
# 0.8.0
Requests per second:    749.17 [#/sec] (mean)

and these read/write results

# 0.6.19, writes
Wrote 1024 byte buffers: 19.428793471925395 mB/s
Wrote 4096 byte buffers: 59.737156511350065 mB/s
Wrote 16384 byte buffers: 83.97010664203543 mB/s
Wrote 65536 byte buffers: 97.4184120798831 mB/s

# 0.8.0, writes
Wrote 1024 byte buffers: 61.236987140232706 mB/s
Wrote 4096 byte buffers: 109.05125408942203 mB/s
Wrote 16384 byte buffers: 182.18254691200585 mB/s
Wrote 65536 byte buffers: 181.91740949608877 mB/s

# v0.6.19, reads
Read 1024 byte buffers: 29.96883241428914 mB/s
Read 4096 byte buffers: 62.34413965087282 mB/s
Read 16384 byte buffers: 165.7550140891762 mB/s
Read 65536 byte buffers: 266.73779674579885 mB/s

# v0.8.0, reads
Read 1024 byte buffers: 57.63688760806916 mB/s
Read 4096 byte buffers: 136.7801942278758 mB/s
Read 16384 byte buffers: 244.8579823702253 mB/s
Read 65536 byte buffers: 302.2974607013301 mB/s

 

2. Node-gyp fully baked into npm for native modules. Node-waf is to be deprecated.

3. More stable – Libuv has not been road tested and all of the major kinks are worked out. “Libuv has come a very long way, and Node 0.8 is a simpler and more efficient machine as a result.”

4. Ability to listen directly on file descriptors e.g. “server.listen({ fd: number })”

5. Cluster module rewrite. Cluster is now much more efficient

6. Domains! – We’ve been wanting this for a while! Domains allow multiple I/O operations to be grouped together contextually for better error handling. A big improvement over the status quo.

So what are you waiting for? Go grab a slice of 0.8!

This entry was posted in node.js. Bookmark the permalink. Follow any comments here with the RSS feed for this post.
  • http://profile.yahoo.com/5LNNNT5VHC6MWDH3MHFSU4QFQ4 Locdrop Team

    Please provide details of the hardware on which benchmark numbers ( using benchmark/http.sh) are calculated. Thanks !