-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: allow specifying an expected object size for resumable operations. #2661
Conversation
&& ed.getErrorInfo() != null | ||
&& ed.getErrorInfo().getReason().equals("GRPC_MISMATCHED_UPLOAD_SIZE"))) { | ||
clientDetectedError( | ||
ResumableSessionFailureScenario.SCENARIO_5.toStorageException( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we get some comments around what Scenario 5 is to make it easier to read?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh i see this was there before as well. my apologies. that can be a followup.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ResumableSessionFailureScenario is an enum that is shared by several of our upload implementations and defines the types of failure scenarios that can happen when processing an upload request.
SCENARIO_5 is client side data loss detected
Lines 72 to 75 in 380057b
SCENARIO_5( | |
BaseServiceException.UNKNOWN_CODE, | |
"dataLoss", | |
"Client side data loss detected. Attempt to append to a resumable session with an offset higher than the backend has"), |
google-cloud-storage/src/main/java/com/google/cloud/storage/GrpcStorageOptions.java
Outdated
Show resolved
Hide resolved
&& ed.getErrorInfo() != null | ||
&& ed.getErrorInfo().getReason().equals("GRPC_MISMATCHED_UPLOAD_SIZE"))) { | ||
clientDetectedError( | ||
ResumableSessionFailureScenario.SCENARIO_5.toStorageException( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh i see this was there before as well. my apologies. that can be a followup.
Update resumable upload failure detection to be more specific about classifying a request as SCENARIO_5 Fixes #2511
Update resumable upload failure detection to be more specific about classifying a request as SCENARIO_5
Fixes #2511