Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

executable file 29 lines (23 sloc) 0.512 kB
#!/usr/bin/env bash
# Adapted from: https://raw.github.com/visionmedia/express/0.14.1/benchmarks/run
SLEEP=${SLEEP-2}
ABFLAGS=${ABFLAGS-"-n 2000 -c 50"}
ADDR=${ADDR-http://127.0.0.1:3000/}
AB=${AB-ab}
export NODE_ENV=production
log(){
echo "... $@"
}
bm(){
local file=$1
log benchmarking $file
coffee $file.coffee &
pid=$!
sleep $SLEEP
$AB $ABFLAGS -g out/$file.dat $ADDR > out/$file.out
log $(cat out/$file.out | grep Requests)
kill -KILL $pid
}
log ab $ABFLAGS $ADDR
bm zappa
bm express
Jump to Line
Something went wrong with that request. Please try again.