Browse Source

found the file handle lost...made a first workaround and added an todo.

master
Georg Hopp 14 years ago
parent
commit
de7e390c78
  1. 6
      ChangeLog
  2. 56
      doc/ab-stress-2012-02-08.txt
  3. 8
      src/socket/accept.c

6
ChangeLog

@ -1,6 +1,10 @@
2012-02-08 11:52:30 +0100 Georg Hopp
* found the file handle lost...made a first workaround and added an todo. (HEAD, master)
2012-02-08 10:21:04 +0100 Georg Hopp
* changed request handling. @TODO: I still seem to have the problem that the file handles are not closed and freed correctly as the service refuses connections after about a 1000. (HEAD, master)
* changed request handling. @TODO: I still seem to have the problem that the file handles are not closed and freed correctly as the service refuses connections after about a 1000.
2012-02-07 14:20:00 +0100 Georg Hopp

56
doc/ab-stress-2012-02-08.txt

@ -0,0 +1,56 @@
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 localhost (be patient)
Completed 200000 requests
Completed 400000 requests
Completed 600000 requests
Completed 800000 requests
Completed 1000000 requests
Completed 1200000 requests
Completed 1400000 requests
Completed 1600000 requests
Completed 1800000 requests
Completed 2000000 requests
Finished 2000000 requests
Server Software: testserver
Server Hostname: localhost
Server Port: 11212
Document Path: /
Document Length: 322 bytes
Concurrency Level: 100
Time taken for tests: 250.130 seconds
Complete requests: 2000000
Failed requests: 0
Write errors: 0
Non-2xx responses: 2000003
Total transferred: 902001353 bytes
HTML transferred: 644000966 bytes
Requests per second: 7995.86 [#/sec] (mean)
Time per request: 12.506 [ms] (mean)
Time per request: 0.125 [ms] (mean, across all concurrent requests)
Transfer rate: 3521.62 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 0 5 1.8 5 23
Processing: 3 7 1.9 7 29
Waiting: 1 6 1.7 5 23
Total: 8 12 2.3 12 36
Percentage of the requests served within a certain time (ms)
50% 12
66% 13
75% 13
80% 14
90% 15
95% 17
98% 19
99% 22
100% 36 (longest request)

8
src/socket/accept.c

@ -13,7 +13,15 @@ socketAccept(Sock this, char remoteAddr[16])
/* Set the size of the in-out parameter */
len = sizeof(this->addr);
/**
* @TODO: Uhh, this is bad. we open a new socket additionally to
* the one we get from the accept call.
* i have to change the socket constructor to be able to create
* the data structure without creation of a socket at all.
* For now i simply close the socket here.... :D
*/
sock = new(Sock, this->log, this->port);
close(sock->handle);
/**
* @TODO: change port to remote port on success
*/

Loading…
Cancel
Save