Skip to content

Print correlation ID in case of request errors

Nailia Iskhakova requested to merge print-correlation-id-when-error into main

MR adds correlation ID to the error output in GPT and k6 requests for better debugging.

Examples:

scenarios: (100.00%) 1 scenario, 2 max VUs, 50s max duration (incl. graceful stop):
           * default: Up to 2 looping VUs for 20s over 3 stages (gracefulRampDown: 30s, gracefulStop: 30s)

time="2021-10-20T22:02:16+03:00" level=info source=console
time="2021-10-20T22:02:16+03:00" level=info msg="RPS Threshold: 0.80/s (16)" source=console
time="2021-10-20T22:02:16+03:00" level=info msg="TTFB P90 Threshold: 2750ms" source=console
time="2021-10-20T22:02:16+03:00" level=info msg="Success Rate Threshold: 99%" source=console
time="2021-10-20T22:02:16+03:00" level=warning msg="Error detected: '404 Not found' ====> Correlation ID: 01FJFHAA5R3SJX49CV8JATV9Q3" source=console
GitLab Performance Tool (GPT) v2.9.0 - Performance test runner for GitLab environments based on k6
Checking that GitLab environment 'http://localhost' is available, supported and that provided Access Token works...
Traceback (most recent call last):
        2: from bin/run-k6:64:in `<main>'
        1: from /Users/niskhakova/GitLab/performance/lib/gpt_common.rb:60:in `check_gitlab_env_and_token'
/GitLab/performance/lib/gpt_common.rb:43:in `make_http_request': GET request failed! (GPTCommon::RequestError)
Code: 404
Response: {"error":"404 Not Found"}
Correlation ID: 01FJFGZGWCBFVAB6A8Y8BXQS00
Edited by Nailia Iskhakova

Merge request reports

Loading