updated with: 4) django Rps: 13331.91 ms 99% 86 5) web2py "plain cheating mode" (read the comments) Rps: 4719.26 ms 99% 250
Just to stress it out a web.py (minimal framework - apples) vs web2py (full framework - oranges) comparison. Hack 10 minutes one single file - no thinking required - to have a more fair comparison between apples and oranges and voilà, bump +50% on "performances". I know, we're still far from django (a more "fair competitor"), but as soon as you start using databases, forms, templates and cookies/sessions, the gap "collapses". --
###### 1) web2py niphlod@li-mostro7:~$ ab -c 1000 -n 1000000 http://127.0.0.1:8080/welcome This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 127.0.0.1 (be patient) .... Finished 1000000 requests Server Software: Server Hostname: 127.0.0.1 Server Port: 8080 Document Path: /welcome Document Length: 12 bytes Concurrency Level: 1000 Time taken for tests: 313.423 seconds Complete requests: 1000000 Failed requests: 0 Write errors: 0 Total transferred: 318000000 bytes HTML transferred: 12000000 bytes Requests per second: 3190.58 [#/sec] (mean) Time per request: 313.423 [ms] (mean) Time per request: 0.313 [ms] (mean, across all concurrent requests) Transfer rate: 990.82 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.4 0 18 Processing: 22 313 13.8 310 400 Waiting: 22 313 13.8 310 399 Total: 40 313 13.7 310 400 Percentage of the requests served within a certain time (ms) 50% 310 66% 313 75% 315 80% 316 90% 321 95% 344 98% 367 99% 369 100% 400 (longest request) ###### 2) web.py (without thread-stacksize = 64, won't work on my rig) niphlod@li-mostro7:~$ ab -c 1000 -n 1000000 http://127.0.0.1:8080/welcome This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 127.0.0.1 (be patient) .... Finished 1000000 requests Server Software: Server Hostname: 127.0.0.1 Server Port: 8080 Document Path: /welcome Document Length: 12 bytes Concurrency Level: 1000 Time taken for tests: 184.617 seconds Complete requests: 1000000 Failed requests: 0 Write errors: 0 Total transferred: 31000000 bytes HTML transferred: 12000000 bytes Requests per second: 5416.62 [#/sec] (mean) Time per request: 184.617 [ms] (mean) Time per request: 0.185 [ms] (mean, across all concurrent requests) Transfer rate: 163.98 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.7 0 22 Processing: 21 184 7.9 183 243 Waiting: 20 184 7.9 183 243 Total: 42 184 7.7 183 243 Percentage of the requests served within a certain time (ms) 50% 183 66% 183 75% 184 80% 184 90% 186 95% 193 98% 216 99% 230 100% 243 (longest request) ###### 3) session.forget() compiled web2py no default redirection ab -c 1000 -n 1000000 http://127.0.0.1:8080/welcome/default/index This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 127.0.0.1 (be patient) .... Finished 1000000 requests Server Software: Server Hostname: 127.0.0.1 Server Port: 8080 Document Path: /welcome/default/index Document Length: 12 bytes Concurrency Level: 1000 Time taken for tests: 302.581 seconds Complete requests: 1000000 Failed requests: 0 Write errors: 0 Total transferred: 230000000 bytes HTML transferred: 12000000 bytes Requests per second: 3304.90 [#/sec] (mean) Time per request: 302.581 [ms] (mean) Time per request: 0.303 [ms] (mean, across all concurrent requests) Transfer rate: 742.31 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.5 0 18 Processing: 22 302 13.6 299 394 Waiting: 22 302 13.6 299 394 Total: 40 302 13.5 299 394 Percentage of the requests served within a certain time (ms) 50% 299 66% 302 75% 303 80% 305 90% 317 95% 333 98% 347 99% 359 100% 394 (longest request) ###### 4) django niphlod@li-mostro7:~$ ab -c 1000 -n 1000000 http://127.0.0.1:8080/welcome This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 127.0.0.1 (be patient) .... Finished 1000000 requests Server Software: Server Hostname: 127.0.0.1 Server Port: 8080 Document Path: /welcome Document Length: 12 bytes Concurrency Level: 1000 Time taken for tests: 75.008 seconds Complete requests: 1000000 Failed requests: 0 Write errors: 0 Total transferred: 71013348 bytes HTML transferred: 12002256 bytes Requests per second: 13331.91 [#/sec] (mean) Time per request: 75.008 [ms] (mean) Time per request: 0.075 [ms] (mean, across all concurrent requests) Transfer rate: 924.55 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 29 7.0 31 37 Processing: 11 46 8.6 47 90 Waiting: 11 37 10.3 37 87 Total: 30 75 6.2 74 96 Percentage of the requests served within a certain time (ms) 50% 74 66% 80 75% 80 80% 80 90% 81 95% 82 98% 84 99% 86 100% 96 (longest request) ###### 5) session.forget() compiled web2py no default redirection, hacked only gluon/main.py ###### This is just plain cheating to have a functional "hello world" application without attaching too much machinery (web.py style): ###### (no static file serving, no checking other apps, no session whatsoever, no request.attrs, no check for debugger, no checking ###### if all the folders for the welcome app are created yet, no check for cron, etc etc etc). There is still plenty of space for stripping niphlod@li-mostro7:~$ ab -c 1000 -n 1000000 http://127.0.0.1:8080/welcome/default/index This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 127.0.0.1 (be patient) .... Finished 1000000 requests Server Software: Server Hostname: 127.0.0.1 Server Port: 8080 Document Path: /welcome/default/index Document Length: 12 bytes Concurrency Level: 1000 Time taken for tests: 211.898 seconds Complete requests: 1000000 Failed requests: 0 Write errors: 0 Total transferred: 230000000 bytes HTML transferred: 12000000 bytes Requests per second: 4719.26 [#/sec] (mean) Time per request: 211.898 [ms] (mean) Time per request: 0.212 [ms] (mean, across all concurrent requests) Transfer rate: 1059.99 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.5 0 19 Processing: 20 212 11.9 209 291 Waiting: 20 212 11.9 209 291 Total: 39 212 11.8 209 291 Percentage of the requests served within a certain time (ms) 50% 209 66% 211 75% 213 80% 215 90% 227 95% 243 98% 248 99% 250 100% 291 (longest request)