1 var common = require('../common.js');
2 var PORT = common.PORT;
4 var cluster = require('cluster');
5 if (cluster.isMaster) {
6 var bench = common.createBenchmark(main, {
7 // unicode confuses ab on os x.
8 type: ['bytes', 'buffer'],
9 length: [4, 1024, 102400],
13 require('../http_simple.js');
17 process.env.PORT = PORT;
19 var w1 = cluster.fork();
20 var w2 = cluster.fork();
22 cluster.on('listening', function() {
27 setTimeout(function() {
28 var path = '/' + conf.type + '/' + conf.length;
29 var args = ['-d', '10s', '-t', 8, '-c', conf.c];
31 bench.http(path, args, function() {