Commit 4e6b53b
chore: add CloudFetch call verification to proxy tests (#111)
## 🥞 Stacked PR
Use this
[link](https://github.com/adbc-drivers/databricks/pull/111/files) to
review incremental changes.
-
[**stack/e.wang/add-thrift-call-verification**](#111)
[[Files
changed](https://github.com/adbc-drivers/databricks/pull/111/files)]
-
[stack/e.wang/fix-cloudfetch-timeout](#112)
[[Files
changed](https://github.com/adbc-drivers/databricks/pull/112/files/fbd12dc00750ec405c2130138ce59f4d1db9c46d..277c10fc5ba030ae3f3f18d4026c38186fc8941f)]
---------
## What's Changed
This PR adds comprehensive call verification to CloudFetch proxy tests
using dynamic baseline measurement.
### Changes
- **Dynamic baseline verification**: Tests now establish baselines by
running queries without failure scenarios, then compare actual vs
expected call counts
- **CloudFetch failure scenarios**: Added verification for:
- cloudfetch_expired_link: Verifies FetchResults is called again to
refresh expired links
- cloudfetch_403: Verifies FetchResults is called again after 403
Forbidden
- cloudfetch_timeout: Verifies retry behavior with configurable timeout
- cloudfetch_connection_reset: Verifies retry behavior on connection
reset
- **Helper methods**: Added CreateProxiedConnectionWithParameters for
tests requiring custom configuration
- **Test infrastructure**: Uses ProxyControlClient to count Thrift
method calls and cloud downloads
### Testing
The tests validate that the driver correctly:
1. Refreshes CloudFetch download links by calling FetchResults again
when links expire or return 403
2. Retries CloudFetch downloads with exponential backoff on timeout or
connection reset
3. Uses dynamic baselines to account for different result set sizes and
prefetch behavior
Note: The CloudFetchTimeout test currently fails because the Thrift
driver does not apply the configured CloudFetch timeout to the
HttpClient. This will be addressed in a follow-up PR.
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent 7c88c8b commit 4e6b53b
File tree
6 files changed
+488
-73
lines changed- .github/workflows
- test-infrastructure
- proxy-server
- tests/csharp
6 files changed
+488
-73
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
337 | 337 | | |
338 | 338 | | |
339 | 339 | | |
340 | | - | |
| 340 | + | |
| 341 | + | |
341 | 342 | | |
342 | 343 | | |
343 | 344 | | |
344 | 345 | | |
345 | 346 | | |
346 | | - | |
| 347 | + | |
347 | 348 | | |
348 | 349 | | |
349 | 350 | | |
| 351 | + | |
350 | 352 | | |
351 | 353 | | |
352 | 354 | | |
353 | | - | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
354 | 369 | | |
355 | 370 | | |
356 | 371 | | |
| |||
381 | 396 | | |
382 | 397 | | |
383 | 398 | | |
384 | | - | |
| 399 | + | |
385 | 400 | | |
386 | 401 | | |
387 | 402 | | |
| |||
425 | 440 | | |
426 | 441 | | |
427 | 442 | | |
428 | | - | |
| 443 | + | |
| 444 | + | |
429 | 445 | | |
430 | 446 | | |
431 | | - | |
| 447 | + | |
| 448 | + | |
432 | 449 | | |
433 | 450 | | |
434 | 451 | | |
| |||
455 | 472 | | |
456 | 473 | | |
457 | 474 | | |
| 475 | + | |
458 | 476 | | |
459 | 477 | | |
460 | 478 | | |
| 479 | + | |
461 | 480 | | |
462 | 481 | | |
463 | 482 | | |
| |||
0 commit comments