Hey Philippe, On 18 Dec 2010, at 17:20, Philippe Marschall wrote:
> Is the response static or do you allocate a byte array for every > response? Despite everything this benchmark is CPU limited. You were right: I added caching (reuse on repeated requests) on repeated requests to my /bytes handler and I can now match your results on my machine (development image, interactive machine load): [s...@voyager:~]$ ab -k -n 10000 -c 10 http://127.0.0.1:1701/bytes/16384 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) Completed 1000 requests Completed 2000 requests Completed 3000 requests Completed 4000 requests Completed 5000 requests Completed 6000 requests Completed 7000 requests Completed 8000 requests Completed 9000 requests Completed 10000 requests Finished 10000 requests Server Software: Zinc Server Hostname: 127.0.0.1 Server Port: 1701 Document Path: /bytes/16384 Document Length: 16384 bytes Concurrency Level: 10 Time taken for tests: 4.319 seconds Complete requests: 10000 Failed requests: 0 Write errors: 0 Keep-Alive requests: 10000 Total transferred: 165610000 bytes HTML transferred: 163840000 bytes Requests per second: 2315.37 [#/sec] (mean) Time per request: 4.319 [ms] (mean) Time per request: 0.432 [ms] (mean, across all concurrent requests) Transfer rate: 37446.17 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 0.0 0 0 Processing: 0 4 1.6 4 30 Waiting: 0 4 1.5 4 27 Total: 0 4 1.6 4 30 Percentage of the requests served within a certain time (ms) 50% 4 66% 5 75% 5 80% 5 90% 6 95% 7 98% 8 99% 9 100% 30 (longest request) Benchmarking is indeed fun (and very dangereous and a time sink). Sven