Commit 4b31465
fix(storage): resolve transport and retry issues (googleapis#8235)
* fix(storage): standardize URL formatting and enhance transport retry
* fix storage transport & retry issues
* fix
* Update handwritten/storage/src/file.ts
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
* fix(storage): interceptors test
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* feat: implement robust storage conformance test retry framework with request interception and test bench integration
* fix: correct response handler for binary/resumable uploads and improve etag check
- Updated `responseHandler` to correctly handle different payload types:
- Plain objects are mutated with `.headers` and `.status` and
returned.
- Binary payloads (Buffer/Stream) return raw data to prevent dangerous
mutations.
- Primitives (e.g., empty strings) return the full `GaxiosResponse`
wrapper to preserve access to headers like `Location` for resumable
upload initiation.
- Fixed `hasPrecondition` logic to safely parse stringified JSON or
inspect objects directly for an `etag` property. This prevents false
positives on raw text payloads containing the word "etag" and false
negatives on object payloads.
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* refactor(storage): replace constructor-based type checks with structural checks and decouple retry logic into idempotent and transient error utilities.
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* refactor(storage): update storage-transport to return full GaxiosResponse and align downstream resource methods
* fix: update file request URL construction to support custom protocol endpoints
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* refactor(storage): introduce ENCRYPTION_ALGORITHM_AES256 constant to replace hardcoded strings in File class
* fix(storage): merge request headers correctly in file.ts and add missing linting suppressions to ServiceObject
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* test: add bytes method to mock Gaxios responses in storage tests
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* test: add bytes method to mock Gaxios response in acl and headers tests
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* test: add bytes method to mock Gaxios response in acl and headers tests
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* test: add bytes method to mock Gaxios response in acl and headers tests
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* test: add bytes method to mock Gaxios response in acl and headers tests
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* fix(storage): standardize URL formatting and enhance transport retry
* refactor(storage): remove Service.ts and migrate logic to StorageTransport (googleapis#8283)
- Remove Service.ts and common.ts files from handwritten/storage
- Migrate remaining functionality to StorageTransport
- chore(ci): upgrade conformance tests to Node 18
* refactor: improve type safety and validation logic in isBucket helper function
---------
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>1 parent 40f27b2 commit 4b31465
8 files changed
Lines changed: 652 additions & 160 deletions
File tree
- handwritten/storage
- src
- nodejs-common
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3470 | 3470 | | |
3471 | 3471 | | |
3472 | 3472 | | |
3473 | | - | |
| 3473 | + | |
3474 | 3474 | | |
3475 | 3475 | | |
3476 | 3476 | | |
3477 | 3477 | | |
3478 | 3478 | | |
3479 | | - | |
| 3479 | + | |
3480 | 3480 | | |
3481 | 3481 | | |
3482 | 3482 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
349 | 349 | | |
350 | 350 | | |
351 | 351 | | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
352 | 357 | | |
353 | 358 | | |
354 | 359 | | |
| |||
1393 | 1398 | | |
1394 | 1399 | | |
1395 | 1400 | | |
1396 | | - | |
| 1401 | + | |
| 1402 | + | |
| 1403 | + | |
| 1404 | + | |
1397 | 1405 | | |
1398 | 1406 | | |
1399 | 1407 | | |
| |||
1405 | 1413 | | |
1406 | 1414 | | |
1407 | 1415 | | |
1408 | | - | |
| 1416 | + | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
| 1421 | + | |
1409 | 1422 | | |
1410 | 1423 | | |
1411 | 1424 | | |
| |||
1639 | 1652 | | |
1640 | 1653 | | |
1641 | 1654 | | |
| 1655 | + | |
| 1656 | + | |
1642 | 1657 | | |
1643 | 1658 | | |
1644 | 1659 | | |
| |||
1652 | 1667 | | |
1653 | 1668 | | |
1654 | 1669 | | |
1655 | | - | |
| 1670 | + | |
1656 | 1671 | | |
1657 | 1672 | | |
1658 | 1673 | | |
| |||
1721 | 1736 | | |
1722 | 1737 | | |
1723 | 1738 | | |
| 1739 | + | |
1724 | 1740 | | |
1725 | 1741 | | |
1726 | 1742 | | |
| |||
1735 | 1751 | | |
1736 | 1752 | | |
1737 | 1753 | | |
1738 | | - | |
| 1754 | + | |
| 1755 | + | |
| 1756 | + | |
1739 | 1757 | | |
1740 | 1758 | | |
1741 | 1759 | | |
| |||
2426 | 2444 | | |
2427 | 2445 | | |
2428 | 2446 | | |
| 2447 | + | |
| 2448 | + | |
| 2449 | + | |
| 2450 | + | |
| 2451 | + | |
| 2452 | + | |
| 2453 | + | |
| 2454 | + | |
| 2455 | + | |
| 2456 | + | |
| 2457 | + | |
| 2458 | + | |
2429 | 2459 | | |
2430 | 2460 | | |
2431 | 2461 | | |
| |||
2485 | 2515 | | |
2486 | 2516 | | |
2487 | 2517 | | |
2488 | | - | |
| 2518 | + | |
| 2519 | + | |
| 2520 | + | |
| 2521 | + | |
2489 | 2522 | | |
2490 | 2523 | | |
2491 | 2524 | | |
| |||
3315 | 3348 | | |
3316 | 3349 | | |
3317 | 3350 | | |
3318 | | - | |
| 3351 | + | |
| 3352 | + | |
| 3353 | + | |
| 3354 | + | |
| 3355 | + | |
3319 | 3356 | | |
3320 | 3357 | | |
3321 | 3358 | | |
| |||
4025 | 4062 | | |
4026 | 4063 | | |
4027 | 4064 | | |
4028 | | - | |
| 4065 | + | |
4029 | 4066 | | |
4030 | 4067 | | |
4031 | 4068 | | |
4032 | 4069 | | |
4033 | | - | |
| 4070 | + | |
4034 | 4071 | | |
4035 | 4072 | | |
4036 | 4073 | | |
| |||
4562 | 4599 | | |
4563 | 4600 | | |
4564 | 4601 | | |
| 4602 | + | |
| 4603 | + | |
| 4604 | + | |
| 4605 | + | |
| 4606 | + | |
| 4607 | + | |
| 4608 | + | |
| 4609 | + | |
| 4610 | + | |
| 4611 | + | |
| 4612 | + | |
4565 | 4613 | | |
4566 | 4614 | | |
4567 | 4615 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
21 | 20 | | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
25 | 24 | | |
26 | 25 | | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
27 | 40 | | |
28 | 41 | | |
29 | 42 | | |
| |||
97 | 110 | | |
98 | 111 | | |
99 | 112 | | |
100 | | - | |
| 113 | + | |
101 | 114 | | |
102 | 115 | | |
103 | 116 | | |
| |||
208 | 221 | | |
209 | 222 | | |
210 | 223 | | |
211 | | - | |
212 | | - | |
| 224 | + | |
| 225 | + | |
213 | 226 | | |
214 | 227 | | |
215 | 228 | | |
| |||
294 | 307 | | |
295 | 308 | | |
296 | 309 | | |
297 | | - | |
298 | | - | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
299 | 314 | | |
300 | 315 | | |
301 | 316 | | |
| |||
441 | 456 | | |
442 | 457 | | |
443 | 458 | | |
444 | | - | |
445 | | - | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
446 | 463 | | |
447 | 464 | | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
448 | 481 | | |
449 | 482 | | |
450 | 483 | | |
451 | 484 | | |
452 | 485 | | |
453 | 486 | | |
454 | 487 | | |
| 488 | + | |
455 | 489 | | |
456 | 490 | | |
457 | | - | |
| 491 | + | |
458 | 492 | | |
459 | 493 | | |
460 | 494 | | |
| |||
499 | 533 | | |
500 | 534 | | |
501 | 535 | | |
502 | | - | |
503 | | - | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
504 | 540 | | |
505 | 541 | | |
506 | 542 | | |
| |||
530 | 566 | | |
531 | 567 | | |
532 | 568 | | |
533 | | - | |
| 569 | + | |
534 | 570 | | |
535 | | - | |
| 571 | + | |
0 commit comments