Skip to content

Commit

Permalink
Add Monitoring Tag to Test Cases (#2163)
Browse files Browse the repository at this point in the history
  • Loading branch information
asanzgom authored Jan 8, 2025
2 parents 9d28a61 + 2a152c0 commit 44cfe57
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Test Existence of Prometheus Alerting Rules
[Tags] Smoke
... Tier1
... ODS-509
... Monitoring
Skip If RHODS Is Self-Managed
Check Prometheus Alerting Rules

Expand All @@ -36,6 +37,7 @@ Test Existence of Prometheus Recording Rules
[Tags] Smoke
... Tier1
... ODS-510
... Monitoring
Skip If RHODS Is Self-Managed
Check Prometheus Recording Rules

Expand All @@ -44,6 +46,7 @@ Test Metric "Notebook CPU Usage" On ODS Prometheus
[Tags] Sanity
... Tier1
... ODS-178
... Monitoring
Skip If RHODS Is Self-Managed
${cpu_usage_before} = Read Current CPU Usage
Run Jupyter Notebook For 5 Minutes
Expand All @@ -56,6 +59,7 @@ Test Metric "Rhods_Total_Users" On ODS Prometheus
[Tags] Sanity
... Tier1
... ODS-628
... Monitoring
Skip If RHODS Is Self-Managed
# Note: the expression ends with "step=1" to obtain the value for current second
${expression} = Set Variable rhods_total_users&step=1
Expand All @@ -81,6 +85,7 @@ Test Metric Existence For "Rhods_Aggregate_Availability" On ODS Prometheus
[Tags] Sanity
... Tier1
... ODS-636
... Monitoring
Skip If RHODS Is Self-Managed
${expression} = Set Variable rhods_aggregate_availability&step=1
${resp} = Prometheus.Run Query ${RHODS_PROMETHEUS_URL} ${RHODS_PROMETHEUS_TOKEN} ${expression}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Verify OpenShift Monitoring Results Are Correct When Running Undefined Queries
[Tags] Sanity
... Tier1
... ODS-173
... Monitoring
Run OpenShift Metrics Query ${METRIC_RHODS_UNDEFINED} username=${OCP_ADMIN_USER.USERNAME} password=${OCP_ADMIN_USER.PASSWORD}
... auth_type=${OCP_ADMIN_USER.AUTH_TYPE} retry_attempts=1
Metrics.Verify Query Results Dont Contain Data
Expand All @@ -37,6 +38,7 @@ Test Billing Metric (Notebook Cpu Usage) On OpenShift Monitoring
[Tags] Sanity
... Tier1
... ODS-175
... Monitoring
Run Jupyter Notebook For 5 Minutes
Verify Previus CPU Usage Is Greater Than Zero
[Teardown] CleanUp JupyterHub And Close All Browsers
Expand All @@ -46,6 +48,7 @@ Test Metric "Rhods_Total_Users" On Cluster Monitoring Prometheus
[Tags] Sanity
... ODS-634
... Tier1
... Monitoring
Skip If RHODS Is Self-Managed
${value} = Run OpenShift Metrics Query query=rhods_total_users username=${OCP_ADMIN_USER.USERNAME} password=${OCP_ADMIN_USER.PASSWORD}
... auth_type=${OCP_ADMIN_USER.AUTH_TYPE}
Expand All @@ -59,7 +62,7 @@ Test Metric "Rhods_Aggregate_Availability" On Cluster Monitoring Prometheus
[Tags] Smoke
... ODS-637
... Tier1
... Monitoring
Skip If RHODS Is Self-Managed

${value_openshift_observe} = Run OpenShift Metrics Query
Expand All @@ -80,7 +83,7 @@ Test Metric "Active_Users" On OpenShift Monitoring On Cluster Monitoring Prometh
[Tags] Sanity
... ODS-1053
... Tier1
... Monitoring
${active_users_before} = Run OpenShift Metrics Query
... username=${OCP_ADMIN_USER.USERNAME} password=${OCP_ADMIN_USER.PASSWORD}
... auth_type=${OCP_ADMIN_USER.AUTH_TYPE} query=cluster:usage:consumption:rhods:active_users
Expand Down Expand Up @@ -110,6 +113,7 @@ Test Metric "Active Notebook Pod Time" On OpenShift Monitoring - Cluster Monitor
[Tags] Sanity
... ODS-1055
... Tier1
... Monitoring
@{list_of_usernames} = Create List ${TEST_USER_3.USERNAME} ${TEST_USER_4.USERNAME}
Log In N Users To JupyterLab And Launch A Notebook For Each Of Them
... list_of_usernames=${list_of_usernames}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ PagerDuty Dummy Secret Verification
... Tier1
... ODS-737
... Deployment-Cli
... Monitoring
Skip If RHODS Is Self-Managed
${service_key} Get PagerDuty Key From Alertmanager ConfigMap
${secret_key} Get PagerDuty Key From Secrets
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Verify All Alerts Severity
[Tags] Smoke
... Tier1
... ODS-1227
... Monitoring
Verify "DeadManSnitch" Alerts Severity And Continue On Failure
Verify "Kubeflow Notebook Controller Pod Is Not Running" Alerts Severity And Continue On Failure
Verify "ODH Notebook Controller Pod Is Not Running" Alerts Severity And Continue On Failure
Expand All @@ -46,7 +46,7 @@ Verify No Alerts Are Firing Except For DeadManSnitch # robocop: disable:too-l
[Tags] Smoke
... Tier1
... ODS-540
... Monitoring
Verify Alert Is Firing And Continue On Failure
... DeadManSnitch DeadManSnitch

Expand All @@ -67,7 +67,7 @@ Verify Alert RHODS-PVC-Usage-Above-90 Is Fired When User PVC Is Above 90 Percent
... verifies that alert "User notebook pvc usage above 90%" is fired
[Tags] Tier2
... ODS-516
... Monitoring
Fill Up User PVC ${NOTEBOOK_REPO_URL} ${TEST_ALERT_PVC90_NOTEBOOK_PATH}

Prometheus.Wait Until Alert Is Firing ${RHODS_PROMETHEUS_URL}
Expand All @@ -83,7 +83,7 @@ Verify Alert RHODS-PVC-Usage-At-100 Is Fired When User PVC Is At 100 Percent
... verifies that alert "User notebook pvc usage at 100%" is fired
[Tags] Tier2
... ODS-517
... Monitoring
Fill Up User PVC ${NOTEBOOK_REPO_URL} ${TEST_ALERT_PVC100_NOTEBOOK_PATH}

Prometheus.Wait Until Alert Is Firing ${RHODS_PROMETHEUS_URL}
Expand All @@ -99,7 +99,7 @@ Verify Alerts Are Fired When RHODS Dashboard Is Down # robocop: disable:too-l
... are fired when rhods-dashboard is not working
[Tags] Tier3
... ODS-739
... Monitoring
Skip If Alert Is Already Firing ${RHODS_PROMETHEUS_URL}
... ${RHODS_PROMETHEUS_TOKEN}
... SLOs-haproxy_backend_http_responses_dashboard
Expand Down Expand Up @@ -145,7 +145,7 @@ Verify Alert "Kubeflow notebook controller pod is not running" Is Fired When Kub
... when notebook-controller-deployment-xxx pod is not running
[Tags] Tier3
... ODS-1700
... Monitoring
Skip If Alert Is Already Firing ${RHODS_PROMETHEUS_URL}
... ${RHODS_PROMETHEUS_TOKEN}
... RHODS Notebook controllers
Expand Down Expand Up @@ -177,7 +177,7 @@ Verify Alert "ODH notebook controller pod is not running" Is Fired When ODH Cont
... when odh-notebook-controller-manager-xxx pod is not running
[Tags] Tier3
... ODS-1701
... Monitoring
Skip If Alert Is Already Firing ${RHODS_PROMETHEUS_URL}
... ${RHODS_PROMETHEUS_TOKEN}
... RHODS Notebook controllers
Expand Down Expand Up @@ -209,7 +209,7 @@ Verify That MT-SRE Are Not Paged For Alerts In Clusters Used For Development Or
[Tags] Sanity
... ODS-1058
... Tier1
... Monitoring
${res} = Check Cluster Name Contain "Aisrhods" Or Not
IF ${res}
${receiver} = Set Variable alerts-sink
Expand Down

0 comments on commit 44cfe57

Please sign in to comment.