egg benchmark
npm test
to run all the benchmarks and store the results in stats.csv
(requires wrk
), also you can open plot/index.html
to see the results./plot.sh
to compare performance between the latest releases of Node.js v7.x, v8.x, rc, nightly and v8-canary (requires wrk
and nvm
), then open plot/index.html
to see the results
plot/all.csv
, you can run python -m SimpleHTTPServer
then visit http://localhost:8000/plot/
(or use any other static server) if you don’t want to tweak browser settings$ EGG_SERVER_ENV=prod node benchmarks/simple/dispatch.js
$ EGG_SERVER_ENV=prod node benchmarks/simple_view/dispatch.js
$ EGG_SERVER_ENV=prod node benchmarks/simple_passport/dispatch.js
wrk http://127.0.0.1:7001/ -d 10 -c 50 -t 8
wrk http://127.0.0.1:7002/ -d 10 -c 50 -t 8
wrk http://127.0.0.1:7003/ -d 10 -c 50 -t 8
wrk http://127.0.0.1:7004/ -d 10 -c 50 -t 8
wrk http://127.0.0.1:7005/ -d 10 -c 50 -t 8
wrk http://127.0.0.1:7006/ -d 10 -c 50 -t 8
Date.now()
cost a lot of CPU time(7%) in meta
middleware and CreateContext
method.