Performance
ACE CLI is not supported anymore
To access ACE CLI, run k9s in split screen mode (see a video below of an example session).
One k9s instance will show container resource usage, in another select ace-cli pod and execute s command to enter the ACE CLI shell.
In console run (change namespace to relevant namespace)
ace performance:k8s --namespace env2-ace --numberOfRequests 10000 --concurrentUsers 100
Sample session (more useful in Full Screen mode :)
What just happened is
CLI:
-
checks if cache is disabled and disables it if it is not, disables it
-
creates two flows and APIs performance/rest (simple flow which calls a rest service) and /performance/echo (flow which echoes back whatever was sent to API in POST request body)
-
enables cache
-
runs sample request with one user with
abtool, to make sure that APIs actually work
Running: ab -k -v 4 -c 1 -n 1 -T application/json -p /tmp/34c649d7-be3f-418d-ad46-e22a9c2af85f.json http://digital-api-orch/performance/echo
This is ApacheBench, Version 2.3 <$Revision: 1843412 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking digital-api-orch (be patient)...INFO: POST header ==
---
POST /performance/echo HTTP/1.0
Connection: Keep-Alive
Content-length: 15
Content-type: application/json
Host: digital-api-orch
User-Agent: ApacheBench/2.3
Accept: */*
---
LOG: header received:
HTTP/1.1 200 OK
X-Powered-By: Express
Access-Control-Allow-Headers: Authorization, Origin, X-Requested-With, Content-Type, Accept
Access-Control-Allow-Origin: *
Content-Type: application/json; charset=utf-8
Content-Length: 68
ETag: W/"44-jRG/b3CgjsiiOoQueLl/XYIIEvU"
Date: Tue, 30 Nov 2021 08:28:47 GMT
Connection: keep-alive
Keep-Alive: timeout=5
{"id":"874db4c6-042b-4b9c-8fe9-48dc6437a63b","echo":{"test":"data"}}
LOG: Response code = 200
..done
Server Software:
Server Hostname: digital-api-orch
Server Port: 80
Document Path: /performance/echo
Document Length: 68 bytes
Concurrency Level: 1
Time taken for tests: 0.024 seconds
Complete requests: 1
Failed requests: 0
Keep-Alive requests: 1
Total transferred: 428 bytes
Total body sent: 192
HTML transferred: 68 bytes
Requests per second: 42.05 [#/sec] (mean)
Time per request: 23.784 [ms] (mean)
Time per request: 23.784 [ms] (mean, across all concurrent requests)
Transfer rate: 17.57 [Kbytes/sec] received
7.88 kb/s sent
25.46 kb/s total
Connection Times (ms)
min mean[+/-sd] median max
Connect: 1 1 0.0 1 1
Processing: 23 23 0.0 23 23
Waiting: 23 23 0.0 23 23
Total: 24 24 0.0 24 24
Running: ab -k -v 4 -c 1 -n 1 -T application/json http://digital-api-orch/performance/rest
This is ApacheBench, Version 2.3 <$Revision: 1843412 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking digital-api-orch (be patient)...INFO: GET header ==
---
GET /performance/rest HTTP/1.0
Connection: Keep-Alive
Host: digital-api-orch
User-Agent: ApacheBench/2.3
Accept: */*
---
LOG: header received:
HTTP/1.1 200 OK
X-Powered-By: Express
Access-Control-Allow-Headers: Authorization, Origin, X-Requested-With, Content-Type, Accept
Access-Control-Allow-Origin: *
Content-Type: application/json; charset=utf-8
Content-Length: 66
ETag: W/"42-eKcWCCaFN+Fvz6XLnjUIycYiBjk"
Date: Tue, 30 Nov 2021 08:28:47 GMT
Connection: keep-alive
Keep-Alive: timeout=5
{"performance":"test","id":"874db4c6-042b-4b9c-8fe9-48dc6437a63b"}
LOG: Response code = 200
..done
Server Software:
Server Hostname: digital-api-orch
Server Port: 80
Document Path: /performance/rest
Document Length: 66 bytes
Concurrency Level: 1
Time taken for tests: 0.109 seconds
Complete requests: 1
Failed requests: 0
Keep-Alive requests: 1
Total transferred: 426 bytes
HTML transferred: 66 bytes
Requests per second: 9.19 [#/sec] (mean)
Time per request: 108.827 [ms] (mean)
Time per request: 108.827 [ms] (mean, across all concurrent requests)
Transfer rate: 3.82 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 1 1 0.0 1 1
Processing: 108 108 0.0 108 108
Waiting: 108 108 0.0 108 108
Total: 109 109 0.0 109 109
- runs performance tests with
abtool
Running: ab -k -v 0 -c 100 -n 10000 -T application/json -p /tmp/c487c170-e5de-4b29-809a-62987ed080c8.json http://digital-api-orch/performance/echo
This is ApacheBench, Version 2.3 <$Revision: 1843412 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking digital-api-orch (be patient)
Server Software:
Server Hostname: digital-api-orch
Server Port: 80
Document Path: /performance/echo
Document Length: 68 bytes
Concurrency Level: 100
Time taken for tests: 30.066 seconds
Complete requests: 10000
Failed requests: 0
Keep-Alive requests: 10000
Total transferred: 4280000 bytes
Total body sent: 1920000
HTML transferred: 680000 bytes
Requests per second: 332.60 [#/sec] (mean)
Time per request: 300.658 [ms] (mean)
Time per request: 3.007 [ms] (mean, across all concurrent requests)
Transfer rate: 139.02 [Kbytes/sec] received
62.36 kb/s sent
201.38 kb/s total
Connection Times (ms)
min mean[+/-sd] median max
Connect: 0 0 0.5 0 12
Processing: 28 300 54.0 301 508
Waiting: 23 300 54.0 301 508
Total: 29 300 54.1 301 513
Percentage of the requests served within a certain time (ms)
50% 301
66% 320
75% 334
80% 343
90% 367
95% 390
98% 417
99% 435
100% 513 (longest request)
› Warning: 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
Running: ab -k -v 0 -c 100 -n 10000 -T application/json http://digital-api-orch/performance/rest
This is ApacheBench, Version 2.3 <$Revision: 1843412 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking digital-api-orch (be patient)
Server Software:
Server Hostname: digital-api-orch
Server Port: 80
Document Path: /performance/rest
Document Length: 66 bytes
Concurrency Level: 100
Time taken for tests: 64.449 seconds
Complete requests: 10000
Failed requests: 0
Keep-Alive requests: 10000
Total transferred: 4260000 bytes
HTML transferred: 660000 bytes
Requests per second: 155.16 [#/sec] (mean)
Time per request: 644.487 [ms] (mean)
Time per request: 6.445 [ms] (mean, across all concurrent requests)
Transfer rate: 64.55 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 0 0 0.5 0 6
Processing: 153 640 223.7 603 1907
Waiting: 147 640 223.7 603 1907
Total: 154 640 223.7 603 1907
Percentage of the requests served within a certain time (ms)
50% 603
66% 702
75% 790
80% 805
90% 910
95% 1003
98% 1185
99% 1309
100% 1907 (longest request)
› Warning: 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
In the video above k9s instance on top returns CPU/MEMORY usage (one can observe that DAL pod is not consuming CPU while load tests are running)
Overall this was good run ACE baseline performance (overhead) is
3msforechoand6msforrest