Skip to content

Instantly share code, notes, and snippets.

@bingeboy
Last active August 29, 2015 13:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bingeboy/10095510 to your computer and use it in GitHub Desktop.
Save bingeboy/10095510 to your computer and use it in GitHub Desktop.
Express vs Restify Apache Benchmark Results

#Express vs Restify Apache Benchmark Results

###Test

$ ab -n 10000 -c 100 http://localhost:3000/

###Versions Details node v0.10.26 restify v2.7.0 express v3.5.1 ApacheBench v2.3 Apache v2.4

###Express Results

Server Hostname:        localhost
Server Port:            3000

Document Path:          /
Document Length:        13 bytes

Concurrency Level:      100
Time taken for tests:   1.951 seconds
Complete requests:      10000
Failed requests:        0
Non-2xx responses:      10000
Total transferred:      1430000 bytes
HTML transferred:       130000 bytes
Requests per second:    5126.07 [#/sec] (mean)
Time per request:       19.508 [ms] (mean)
Time per request:       0.195 [ms] (mean, across all concurrent requests)
Transfer rate:          715.85 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    1   2.0      0      91
Processing:     2   19  12.2     16     103
Waiting:        2   19  12.1     16     103
Total:          7   19  12.2     17     104

Percentage of the requests served within a certain time (ms)
  50%     17
  66%     18
  75%     19
  80%     20
  90%     22
  95%     26
  98%     80
  99%     89
 100%    104 (longest request)

###Restify

Server Software:
Server Hostname:        localhost
Server Port:            3000

Document Path:          /
Document Length:        56 bytes

Concurrency Level:      100
Time taken for tests:   3.394 seconds
Complete requests:      10000
Failed requests:        0
Non-2xx responses:      10000
Total transferred:      1900000 bytes
HTML transferred:       560000 bytes
Requests per second:    2946.62 [#/sec] (mean)
Time per request:       33.937 [ms] (mean)
Time per request:       0.339 [ms] (mean, across all concurrent requests)
Transfer rate:          546.74 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.9      0      27
Processing:     8   33   7.5     33      67
Waiting:        8   33   7.4     33      67
Total:         12   34   7.3     33      68

Percentage of the requests served within a certain time (ms)
  50%     33
  66%     36
  75%     38
  80%     39
  90%     42
  95%     47
  98%     54
  99%     57
 100%     68 (longest request)
@bingeboy
Copy link
Author

bingeboy commented Apr 8, 2014

Further testing has proven that I need a better test since numbers are jumping back and forth for each framework.

@andrecaribe
Copy link

Why document length in Restify (56 bytes) is larger than Express (13 bytes)? The longest requests in Restify is better too. Did you use gzip in Restify?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment