Hi Jeff,
30 requests are not a lot. Are these results stable?
When I tried to repeat your results, I started the server
with your configuration:
/usr/local/ns/bin/nsd -u nsadmin -t ~/scripts/aol/jeff-conf.tcl -f
When running "ab" without -k" and 1000 requests:
ab -n 1000 -c 1 http://localhost:8080/hello.html
...
Time per request: 0.168 [ms] (mean)
When running "ab" with -k" and 1000 requests:
ab -k -n 1000 -c 1 http://localhost:8080/hello.html
...
Time per request: 0.098 [ms] (mean)
The results of "ab" are most probably platform dependent.
My results are on a notebook with macOS Darwin 17.7.0,
NaviServer 4.99.17, some snapshot of Tcl 8.7,
most components without C-level optimization.
The reported times show that the keepalive option
improves the results, which is an expected result.
With high numbers for "-c", "ab" hangs sometimes, but that
might be a problem with "ab" on the mac (Apple version);
i remember that i had to fix "ab" in the past in order to get results
on the mac at all.
all the best
-gn
On 29.11.18 23:48, Jeff Rogers wrote:
Hi all,
I am running a test using ab against a local naviserver instance with
a vanilla config, and I am seeing requests with http keepalive enabled
having a delay of ~38ms per request compared to non-keepalive. This
rather surprised me; is there a config setting to avoid that delay,
or is it otherwise to be expected?
My config:
ns_section "ns/servers"
ns_param default Naviserver
ns_section "ns/server/default"
ns_param minthreads 20
ns_section "ns/server/default/modules"
ns_param nscp nscp.so
ns_param nssock nssock.so
ns_param nslog nslog.so
ns_section "ns/server/default/module/nssock"
ns_param port 8080
Tests:
$ ab -n 30 -c 1 http://localhost:8080/hello.html
...
Time per request: 0.170 [ms] (mean)
$ ab -k -n 30 -c 1 http://localhost:8080/hello.html
...
Time per request: 38.666 [ms] (mean)
_______________________________________________
naviserver-devel mailing list
naviserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/naviserver-devel