1 .. This work is licensed under a
2 .. Creative Commons Attribution 4.0 International License.
3 .. http://creativecommons.org/licenses/by/4.0
10 Policy Clamp Automation Composition
11 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
13 Both the Performance and the Stability tests were executed by performing requests
14 against acm components installed as docker images in local environment. These tests we all
15 performed on a Ubuntu VM with 32GB of memory, 16 CPU and 50GB of disk space.
21 In an effort to allow the execution of the s3p tests to be as close to automatic as possible,
22 a script will be executed that will perform the following:
24 - Install of a microk8s kubernetes environment
25 - Bring up the policy components
26 - Checks that the components are successfully up and running before proceeding
28 - Install Jmeter locally and configure it
29 - Specify whether you want to run stability or performance tests
32 The remainder of this document outlines how to run the tests and the test results
36 The common setup for performance and stability tests is now automated - being carried out by a script in- **testsuites/run-s3p-test.sh**.
38 Clone the policy-clamp repo to access the test scripts
42 git clone https://gerrit.onap.org/r/policy/clamp
44 Stability Test of acm components
45 ++++++++++++++++++++++++++++++++
49 The 72 hours stability test ran the following steps sequentially in a single threaded loop.
51 - **Commission Automation Composition Definitions** - Commissions the ACM Definitions
52 - **Register Participants** - Registers the presence of participants in the acm database
53 - **Prime AC definition** - Primes the AC Definition to the participants
54 - **Instantiate acm** - Instantiate the acm instance
55 - **DEPLOY the ACM instance** - change the state of the acm to DEPLOYED
56 - **Check instance state** - check the current state of instance and that it is DEPLOYED
57 - **UNDEPLOY the ACM instance** - change the state of the ACM to UNDEPLOYED
58 - **Check instance state** - check the current state of instance and that it is UNDEPLOYED
59 - **Delete instance** - delete the instance from all participants and ACM db
60 - **DEPRIME ACM definitions** - DEPRIME ACM definitions from participants
61 - **Delete ACM Definition** - delete the ACM definition on runtime
63 This runs for 72 hours. Test results are present in the **testsuites/automated-performance/s3pTestResults.jtl**
64 directory. Logs are present for jmeter in **testsuites/automated-performance/jmeter.log** and
65 **testsuites/automated-performance/nohup.out**
70 The code in the setup section also serves to run the tests. Just one execution needed to do it all.
74 ./run-s3p-test.sh run stability
76 Once the test execution is completed, the results are present in the **automate-performance/s3pTestResults.jtl** file.
78 This file can be imported into the Jmeter GUI for visualization. The below results are tabulated from the GUI.
85 Stability test plan was triggered for 72 hours.
89 ======================= ================= ================== ==================================
90 **Total # of requests** **Success %** **Error %** **Average time taken per request**
91 ======================= ================= ================== ==================================
92 261852 100.00 % 0.00 % 387.126 ms
93 ======================= ================= ================== ==================================
95 **ACM component Setup**
97 ============================================== ================================================================== ====================
98 **NAME** **IMAGE** **PORT**
99 ============================================== ================================================================== ====================
100 zookeeper-deployment-7ff87c7fcc-ptkwv confluentinc/cp-zookeeper:latest 2181/TCP
101 kafka-deployment-5c87d497b-2jv27 confluentinc/cp-kafka:latest 9092/TCP
102 policy-models-simulator-6947667bdc-v4czs nexus3.onap.org:10001/onap/policy-models-simulator:latest 3904:30904/TCP
103 prometheus-f66f97b6-rknvp nexus3.onap.org:10001/prom/prometheus:latest 9090:30909/TCP
104 mariadb-galera-0 nexus3.onap.org:10001/bitnami/mariadb-galera:10.5.8 3306/TCP
105 policy-apex-pdp-0 nexus3.onap.org:10001/onap/policy-apex-pdp:3.1.3-SNAPSHOT 6969:30001/TCP
106 policy-clamp-ac-http-ppnt-7d747b5d98-4phjf nexus3.onap.org:10001/onap/policy-clamp-ac-http-ppnt7.1.3-SNAPSHOT 8084/TCP
107 policy-clamp-ac-sim-ppnt-97f487577-4p7ks nexus3.onap.org:10001/onap/policy-clamp-ac-sim-ppnt7.1.3-SNAPSHOT 6969/TCP
108 policy-clamp-ac-k8s-ppnt-6bbd86bbc6-csknn nexus3.onap.org:10001/onap/policy-clamp-ac-k8s-ppnt7.1.3-SNAPSHOT 8083:30443/TCP
109 policy-clamp-ac-pf-ppnt-5fcbbcdb6c-twkxw nexus3.onap.org:10001/onap/policy-clamp-ac-pf-ppnt7.1.3-SNAPSHOT 6969:30008/TCP
110 policy-clamp-runtime-acm-66b5d6b64-4gnth nexus3.onap.org:10001/onap/policy-clamp-runtime-acm7.1.3-SNAPSHOT 6969:30007/TCP
111 policy-pap-f7899d4cd-7m898 nexus3.onap.org:10001/onap/policy-pap:3.1.3-SNAPSHOT 6969:30003/TCP
112 policy-api-7f7d995b4-ckb84 nexus3.onap.org:10001/onap/policy-api:3.1.3-SNAPSHOT 6969:30002/TCP
113 ============================================== ================================================================== ====================
119 .. container:: paragraph
121 There were no failures during the 72 hours test.
123 **JMeter Screenshot**
125 .. image:: clamp-s3p-results/acm_stability_jmeter.png
127 **JMeter Screenshot**
129 .. image:: clamp-s3p-results/acm_stability_table.png
132 Performance Test of acm components
133 ++++++++++++++++++++++++++++++++++
138 Performance test of acm components has the goal of testing the min/avg/max processing time and rest call throughput for all the requests with multiple requests at the same time.
143 We can setup the environment and execute the tests like this from the **clamp/testsuites** directory
147 ./run-s3p-test.sh run performance
149 Test results are present in the **testsuites/automate-performance/s3pTestResults.jtl**
150 directory. Logs are present for jmeter in **testsuites/automate-performance/jmeter.log** and
151 **testsuites/automated-performance/nohup.out**
156 The Performance test ran the following steps sequentially by 5 threaded users. Any user will create 100 compositions/instances.
158 - **SetUp** - SetUp Thread Group
159 - **Register Participants** - Registers the presence of participants in the acm database
160 - **AutomationComposition Test Flow** - flow by 5 threaded users.
161 - **Creation and Deploy** - Creates 100 Compositions and Instances
162 - **Commission Automation Composition Definitions** - Commissions the ACM Definitions
163 - **Prime AC definition** - Primes the AC Definition to the participants
164 - **Instantiate acm** - Instantiate the acm instance
165 - **DEPLOY the ACM instance** - change the state of the acm to DEPLOYED
166 - **Check instance state** - check the current state of instance and that it is DEPLOYED
167 - **Get participants** - fetch all participants
168 - **Get compositions** - fetch all compositions
169 - **Undeploy and Delete** - Deletes instances and Compositions created before
170 - **UNDEPLOY the ACM instance** - change the state of the ACM to UNDEPLOYED
171 - **Check instance state** - check the current state of instance and that it is UNDEPLOYED
172 - **Delete instance** - delete the instance from all participants and ACM db
173 - **DEPRIME ACM definitions** - DEPRIME ACM definitions from participants
174 - **Delete ACM Definition** - delete the ACM definition on runtime
179 The code in the setup section also serves to run the tests. Just one execution needed to do it all.
183 ./run-s3p-test.sh run performance
185 Once the test execution is completed, the results are present in the **automate-performance/s3pTestResults.jtl** file.
187 This file can be imported into the Jmeter GUI for visualization. The below results are tabulated from the Jmeter GUI.
192 Test results are shown as below.
196 ======================= ================= ================== ==================================
197 **Total # of requests** **Success %** **Error %** **Average time taken per request**
198 ======================= ================= ================== ==================================
199 8624 100 % 0.00 % 1296.8 ms
200 ======================= ================= ================== ==================================
202 **ACM component Setup**
204 ============================================== ================================================================== ====================
205 **NAME** **IMAGE** **PORT**
206 ============================================== ================================================================== ====================
207 zookeeper-deployment-7ff87c7fcc-5svgw confluentinc/cp-zookeeper:latest 2181/TCP
208 kafka-deployment-5c87d497b-hmbhc confluentinc/cp-kafka:latest 9092/TCP
209 policy-models-simulator-6947667bdc-crcwq nexus3.onap.org:10001/onap/policy-models-simulator:latest 3904:30904/TCP
210 prometheus-f66f97b6-24dvx nexus3.onap.org:10001/prom/prometheus:latest 9090:30909/TCP
211 mariadb-galera-0 nexus3.onap.org:10001/bitnami/mariadb-galera:10.5.8 3306/TCP
212 policy-apex-pdp-0 nexus3.onap.org:10001/onap/policy-apex-pdp:3.1.3-SNAPSHOT 6969:30001/TCP
213 policy-clamp-ac-sim-ppnt-97f487577-pn56t nexus3.onap.org:10001/onap/policy-clamp-ac-sim-ppnt7.1.3-SNAPSHOT 6969/TCP
214 policy-clamp-ac-http-ppnt-7d747b5d98-qjjlv nexus3.onap.org:10001/onap/policy-clamp-ac-http-ppnt7.1.3-SNAPSHOT 8084/TCP
215 policy-clamp-ac-k8s-ppnt-6bbd86bbc6-ffbz2 nexus3.onap.org:10001/onap/policy-clamp-ac-k8s-ppnt7.1.3-SNAPSHOT 8083:30443/TCP
216 policy-clamp-ac-pf-ppnt-5fcbbcdb6c-vmsnv nexus3.onap.org:10001/onap/policy-clamp-ac-pf-ppnt7.1.3-SNAPSHOT 6969:30008/TCP
217 policy-clamp-runtime-acm-66b5d6b64-6vjl5 nexus3.onap.org:10001/onap/policy-clamp-runtime-acm7.1.3-SNAPSHOT 6969:30007/TCP
218 policy-pap-f7899d4cd-8sjk9 nexus3.onap.org:10001/onap/policy-pap:3.1.3-SNAPSHOT 6969:30003/TCP
219 policy-api-7f7d995b4-dktdw nexus3.onap.org:10001/onap/policy-api:3.1.3-SNAPSHOT 6969:30002/TCP
220 ============================================== ================================================================== ====================
222 **JMeter Screenshot**
224 .. image:: clamp-s3p-results/acm_performance_jmeter.png