Skip to content

Commit

Permalink
Merge "test-monitoring - fetching metrics - wait for not null value"
Browse files Browse the repository at this point in the history
  • Loading branch information
Microzuul CI authored and Gerrit Code Review committed Nov 22, 2023
2 parents cacbadb + 156e656 commit 4bc6b2f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions roles/health-check/test-monitoring/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,17 @@
- name: Fetch a basic Zuul metric exporter by statsd
ansible.builtin.shell: curl -k https://{{ prometheus_host }}/api/v1/query?query=zuul_executors_online | jq '.data.result[0].value[1]'
register: zeo
until: zeo.stdout != "" and "null" not in zeo.stdout
retries: 60
delay: 1

# config-update-nodepool-builder should at least trigger one tick for readiness.
- name: Fetch a basic Nodepool metric exported by statsd
ansible.builtin.shell: curl -k https://{{ prometheus_host }}/api/v1/query?query=nodepool_launch_ready | jq '.data.result[0].value[1]'
register: nlr
until: nlr.stdout != "" and "null" not in nlr.stdout
retries: 60
delay: 1

# Use a dictionary to trick Ansible into casting metrics to int/float
- set_fact:
Expand Down

0 comments on commit 4bc6b2f

Please sign in to comment.