- Notifications
You must be signed in to change notification settings - Fork90
Commit5c9cecf
authored
fix: update grpc bidi resumable uploads to validate ack'd object size (#2570)
* fix: update grpc bidi resumable uploads to validate ack'd object sizeFollow up to#2527Part 1, add tests and simulation server* fix: update grpc bidi resumable uploads to validate ack'd object sizeFollow up to#2527Cleanup unused inner-class* fix: update grpc bidi resumable uploads to validate ack'd object sizeFollow up to#2527Move request trimming inline rather than at the end* fix: update grpc bidi resumable uploads to validate ack'd object sizeFollow up to#2527Update GapicBidiUnbufferedWritableByteChannel to correctly handle failure scenarios {1, 2, 3, 4, 4_1, 4_2, 5, 7}Refactor ResumableSessionFailureScenario to accept Message and List rather than WriteObjectResponse and List<WriteObjectRequest>.The shape of BidiWriteObjectRequest/WriteObjectRequest and BidiWriteObjectResponse/WriteObjectResponse are largely the same (bidi has two extra fields) so rather than overloading toStorageException yet again, this time there is a single method for grpc messages that internally can branch when formatting the request. In this case, we're quite safe taking this relaxed typing because it is an internal API that is only called from a grpc context where protos will be used.* fix: update grpc bidi resumable uploads to validate ack'd object sizeFollow up to#2527Update GapicBidiUnbufferedWritableByteChannel to correctly handle partial consumption of contentTests passing now.Separate tracking of client detected errors and stream errors.When await is invoked, if a client detected error is present AND a stream error is present, the client detected error will take precedence. If a stream error happens and the client detected error has not yet been observed, the stream error will be added as a suppressed exception to the client detected error.* chore: fix failing tests1 parent55a6d15 commit5c9cecf
File tree
8 files changed
+1340
-160
lines changed- google-cloud-storage/src
- main/java/com/google/cloud/storage
- test/java/com/google/cloud/storage
- it
8 files changed
+1340
-160
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
Lines changed: 0 additions & 33 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | 19 | | |
22 | 20 | | |
23 | 21 | | |
| |||
84 | 82 | | |
85 | 83 | | |
86 | 84 | | |
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 | 85 | | |
119 | 86 | | |
0 commit comments
Comments
(0)