diff --git a/docs/nodevertical.md b/docs/nodevertical.md index f4600d9a..6f5e5d66 100644 --- a/docs/nodevertical.md +++ b/docs/nodevertical.md @@ -150,8 +150,31 @@ Period of time (in seconds) that cluster loader will wait for pods to come up to Default: `600` Pass/fail criteria. Value to determine if NodeVertical workload executed in duration expected. -## Smoke test variables +### NODEVERTICAL_HEAVY +Default: `false` +Trigger nodevertical heavy workload. Rather than deploy sleep pods throughout all labeled nodes, this workload deploys a two layer application composed by a PostgreSQL database pod and another pod wih simple application that is able to perform several operations and store a result in the database. [Heavy node vertical app](https://github.com/rsevilla87/perfApp) + +### NODEVERTICAL_HEAVY_PROBE_ENDPOINT +Default: `/ready` +Readiness probe endpoint for the application deployed by the heavy nodevertical. The default `/ready` endpoint inserts a record with the current timestamp in the ts table of the DDBB. i.e. `INSERT INTO ts VALUES ('2006-01-02T15:04:05Z07:00')` + +Be aware that using nodevertical heavy has an extra resource consumption compared with the standard workload, +the following capture provides an idea about how much resources are required to run it. + +Results obtained from running 250 pods (client + database) with the default `/ready` endpoint. +``` +root@ip-172-31-76-65: ~ # oc adm top nodes -l nodevertical=true +NAME CPU(cores) CPU% MEMORY(bytes) MEMORY% +ip-10-0-143-79.us-west-2.compute.internal 755m 10% 8495Mi 28% +ip-10-0-155-81.us-west-2.compute.internal 732m 9% 8810Mi 29% +ip-10-0-166-82.us-west-2.compute.internal 753m 10% 9116Mi 30% +``` +### NODEVERTICAL_HEAVY_PROBE_PERIOD +Default: `30` +Readiness probe period for the application deployed by the heavy nodevertical. + +## Smoke test variables ``` NODEVERTICAL_NODE_COUNT=4 NODEVERTICAL_TEST_PREFIX=nodevertical_smoke diff --git a/workloads/nodevertical.yml b/workloads/nodevertical.yml index 92b12bbe..0efa2d1a 100644 --- a/workloads/nodevertical.yml +++ b/workloads/nodevertical.yml @@ -91,7 +91,7 @@ - name: Set NodeVertical template set_fact: - nodevertical_template: "{% if nodevertical_heavy %}workload-nodevertical-heavy-script-cm.yml.j2{% else %}workload-nodevertical-script-cm.yml.j2{% endif %}" + nodevertical_template: "{% if nodevertical_heavy|bool %}workload-nodevertical-heavy-script-cm.yml.j2{% else %}workload-nodevertical-script-cm.yml.j2{% endif %}" - name: Template workload templates template: diff --git a/workloads/templates/workload-nodevertical-heavy-script-cm.yml.j2 b/workloads/templates/workload-nodevertical-heavy-script-cm.yml.j2 index bbb374b3..8a2e4701 100644 --- a/workloads/templates/workload-nodevertical-heavy-script-cm.yml.j2 +++ b/workloads/templates/workload-nodevertical-heavy-script-cm.yml.j2 @@ -134,8 +134,8 @@ data: metadata: name: perf-app objects: - - kind: DeploymentConfig - apiVersion: v1 + - kind: Deployment + apiVersion: apps/v1 metadata: name: postgres-${IDENTIFIER} spec: @@ -169,13 +169,14 @@ data: serviceAccount: '' replicas: 1 selector: - name: postgres-${IDENTIFIER} + matchLabels: + name: postgres-${IDENTIFIER} triggers: - type: ConfigChange strategy: - type: Rolling - - kind: DeploymentConfig - apiVersion: v1 + type: RollingUpdate + - kind: Deployment + apiVersion: apps/v1 metadata: name: perfapp-${IDENTIFIER} spec: @@ -223,11 +224,12 @@ data: serviceAccount: '' replicas: 1 selector: - name: perfapp-${IDENTIFIER} + matchLabels: + name: perfapp-${IDENTIFIER} triggers: - type: ConfigChange strategy: - type: Rolling + type: RollingUpdate - kind: Service apiVersion: v1 metadata: