I have a question - does anyone has any benchmark data re. using Express JS framework vs pure Node.js?
Is this something that even should be considered -- or using Express or similar framework is definitely a MUST if you're building a more or less large web app?
Fastify claims to be the fastest web framework around. Benchmarks back up their claim with Fastify performing nearly twice as fast as Express in a simple 'hello world' overhead benchmark. The only case where Fastify falls behind Express is in handling empty requests.
ExpressJS and Restify belong to "Microframeworks (Backend)" category of the tech stack. ExpressJS and Restify are both open source tools. It seems that ExpressJS with 44.6K GitHub stars and 7.48K forks on GitHub has more adoption than Restify with 9.31K GitHub stars and 957 GitHub forks.
Express — 367,069 responses per second with an average latency of 354.1 ms.
EDIT:
The article I linked to below disappeared, and I couldn't find it after searching around a bit. However, in lieu of that, here are a couple of relevant references with sufficiently scientific benchmarks:
- https://github.com/koajs/koa/blob/master/docs/koa-vs-express.md#is-koa-faster-than-express
- http://serdardogruyol.com/?p=111
- http://qzaidi.github.io/2013/07/20/surprises/
Although this doesn't answer the delta part of your question, there's some absolute statistics about ExpressJS performance here:
Updated Link
http://blog.perfectapi.com/2012/benchmarking-apis-using-perfectapi-vs-express.js-vs-restify.js/
Looks like, on a small Amazon instance, Express averages:
a very respectable 1,600-1,700 requests per second
Express is a convenience wrapper around node.js, and should not add much latency to your server; your code would probably go through many of the same steps anyway. That being said, if your load tests (or hapless customers) find the server is too slow and/or not scalable, then you should profile at that time, and the bottleneck probably won't be Express.
BTW, even though Express calls itself "high performance", they're naughty for not posting measurements.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With