Commit eb66a3a
committed
http: add trace2 logging for retry operations
Add trace2 instrumentation to HTTP 429 retry operations to enable
monitoring and debugging of rate limit scenarios in production
environments.
The trace2 logging captures:
* Retry attempt numbers (http/429-retry-attempt) to track retry
progression and identify how many attempts were needed
* Retry-After header values (http/429-retry-after) from server
responses to understand server-requested delays
* Actual sleep durations (http/retry-sleep-seconds) within trace2
regions (http/retry-sleep) to measure time spent waiting
* Error conditions (http/429-error) such as "retries-exhausted",
"exceeds-max-retry-time", "no-retry-after-config", and
"config-exceeds-max-retry-time" for diagnosing failures
* Retry source (http/429-retry-source) indicating whether delay
came from server header or config default
This instrumentation provides complete visibility into retry behavior,
enabling operators to monitor rate limiting patterns, diagnose retry
failures, and optimize retry configuration based on real-world data.
Signed-off-by: Vaidas Pilkauskas <vaidas.pilkauskas@shopify.com>1 parent a6dc9ef commit eb66a3a
1 file changed
+31
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
27 | 28 | | |
28 | 29 | | |
| |||
1944 | 1945 | | |
1945 | 1946 | | |
1946 | 1947 | | |
| 1948 | + | |
| 1949 | + | |
1947 | 1950 | | |
1948 | 1951 | | |
1949 | 1952 | | |
| |||
2338 | 2341 | | |
2339 | 2342 | | |
2340 | 2343 | | |
| 2344 | + | |
| 2345 | + | |
| 2346 | + | |
2341 | 2347 | | |
2342 | 2348 | | |
2343 | 2349 | | |
2344 | 2350 | | |
2345 | 2351 | | |
| 2352 | + | |
2346 | 2353 | | |
2347 | 2354 | | |
2348 | 2355 | | |
| |||
2400 | 2407 | | |
2401 | 2408 | | |
2402 | 2409 | | |
| 2410 | + | |
| 2411 | + | |
| 2412 | + | |
2403 | 2413 | | |
2404 | 2414 | | |
2405 | 2415 | | |
2406 | 2416 | | |
| 2417 | + | |
| 2418 | + | |
2407 | 2419 | | |
2408 | 2420 | | |
2409 | 2421 | | |
| |||
2418 | 2430 | | |
2419 | 2431 | | |
2420 | 2432 | | |
| 2433 | + | |
| 2434 | + | |
| 2435 | + | |
| 2436 | + | |
2421 | 2437 | | |
2422 | 2438 | | |
2423 | 2439 | | |
| |||
2429 | 2445 | | |
2430 | 2446 | | |
2431 | 2447 | | |
| 2448 | + | |
| 2449 | + | |
2432 | 2450 | | |
2433 | 2451 | | |
2434 | | - | |
2435 | | - | |
2436 | | - | |
2437 | | - | |
2438 | | - | |
2439 | | - | |
2440 | | - | |
2441 | | - | |
2442 | | - | |
| 2452 | + | |
| 2453 | + | |
| 2454 | + | |
| 2455 | + | |
| 2456 | + | |
| 2457 | + | |
| 2458 | + | |
| 2459 | + | |
| 2460 | + | |
| 2461 | + | |
| 2462 | + | |
| 2463 | + | |
| 2464 | + | |
2443 | 2465 | | |
2444 | 2466 | | |
2445 | 2467 | | |
| |||
0 commit comments