Skip to content

Instantly share code, notes, and snippets.

@machadogj
Created November 2, 2012 20:19
Show Gist options
  • Save machadogj/4004085 to your computer and use it in GitHub Desktop.
Save machadogj/4004085 to your computer and use it in GitHub Desktop.
Express App Load Tests
PS D:\apache\bin> .\ab.exe -n 100 http://one.org:3000/
This is ApacheBench, Version 2.3 <$Revision: 1373084 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking one.org (be patient).....done
Server Software:
Server Hostname: one.org
Server Port: 3000
Document Path: /
Document Length: 11 bytes
Concurrency Level: 1
Time taken for tests: 43.013 seconds
Complete requests: 100
Failed requests: 0
Write errors: 0
Total transferred: 7200 bytes
HTML transferred: 1100 bytes
Requests per second: 2.32 [#/sec] (mean)
Time per request: 430.135 [ms] (mean)
Time per request: 430.135 [ms] (mean, across all concurrent requests)
Transfer rate: 0.16 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 163 217 299.3 180 3174
Processing: 164 213 153.7 178 1196
Waiting: 163 193 67.6 177 818
Total: 331 430 333.8 360 3352
Percentage of the requests served within a certain time (ms)
50% 360
66% 373
75% 409
80% 409
90% 438
95% 549
98% 1376
99% 3352
100% 3352 (longest request)
PS D:\Users\gustavo\Downloads\xampp-win32-1.8.1-VC9\xampp\apache\bin>
PS D:\apache\bin> .\ab.exe -n 100 -c 10 http://one.org:3000/
This is ApacheBench, Version 2.3 <$Revision: 1373084 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking one.org (be patient).....done
Server Software:
Server Hostname: one.org
Server Port: 3000
Document Path: /
Document Length: 11 bytes
Concurrency Level: 10
Time taken for tests: 33.868 seconds
Complete requests: 100
Failed requests: 0
Write errors: 0
Total transferred: 7200 bytes
HTML transferred: 1100 bytes
Requests per second: 2.95 [#/sec] (mean)
Time per request: 3386.794 [ms] (mean)
Time per request: 338.679 [ms] (mean, across all concurrent requests)
Transfer rate: 0.21 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 166 332 655.1 180 3179
Processing: 174 2916 1859.0 1710 7730
Waiting: 172 1807 1819.3 1087 7711
Total: 345 3247 1966.6 1902 7920
Percentage of the requests served within a certain time (ms)
50% 1902
66% 4772
75% 4797
80% 4806
90% 4919
95% 7893
98% 7910
99% 7920
100% 7920 (longest request)
PS D:\apache\bin> .\ab.exe -n 100 -c 100 http://one.org:3000/
This is ApacheBench, Version 2.3 <$Revision: 1373084 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking one.org (be patient).....done
Server Software:
Server Hostname: one.org
Server Port: 3000
Document Path: /
Document Length: 11 bytes
Concurrency Level: 100
Time taken for tests: 24.461 seconds
Complete requests: 100
Failed requests: 0
Write errors: 0
Total transferred: 7200 bytes
HTML transferred: 1100 bytes
Requests per second: 4.09 [#/sec] (mean)
Time per request: 24461.399 [ms] (mean)
Time per request: 244.614 [ms] (mean, across all concurrent requests)
Transfer rate: 0.29 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 169 243 421.5 182 3186
Processing: 176 11577 6957.0 12016 24111
Waiting: 176 11569 6960.8 12008 24110
Total: 355 11820 6973.0 12207 24286
Percentage of the requests served within a certain time (ms)
50% 12207
66% 15175
75% 16797
80% 17738
90% 22609
95% 23527
98% 24111
99% 24286
100% 24286 (longest request)
/**
* Module dependencies.
*/
var express = require('express')
, routes = require('./routes')
, user = require('./routes/user')
, http = require('http')
, path = require('path');
var app = express();
app.configure(function(){
app.set('port', process.env.PORT || 3000);
app.set('views', __dirname + '/views');
app.set('view engine', 'jade');
app.use(express.favicon());
app.use(express.bodyParser());
app.use(express.methodOverride());
app.use(app.router);
app.use(express.static(path.join(__dirname, 'public')));
});
app.configure('development', function(){
app.use(express.errorHandler());
});
app.get('/', function ( req, res ) {
res.end("hello world");
});
app.get('/users', user.list);
http.createServer(app).listen(app.get('port'), function(){
console.log("Express server listening on port " + app.get('port'));
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment