Module: Gapic::Rest::ResumableUpload
- Defined in:
- lib/gapic/rest/resumable_upload.rb,
lib/gapic/rest/resumable_upload/core.rb,
lib/gapic/rest/resumable_upload/rules.rb,
lib/gapic/rest/resumable_upload/driver.rb,
lib/gapic/rest/resumable_upload/errors.rb,
lib/gapic/rest/resumable_upload/events.rb,
lib/gapic/rest/resumable_upload/data_types.rb,
lib/gapic/rest/resumable_upload/instructions.rb,
lib/gapic/rest/resumable_upload/driver/abridge.rb,
lib/gapic/rest/resumable_upload/retry_policies.rb,
lib/gapic/rest/resumable_upload/driver/upload_log.rb,
lib/gapic/rest/resumable_upload/driver/retry_decider.rb
Overview
Resumable Upload Protocol implementation for REST transport: session initiation, chunked streaming, automatic retries, progress reporting via Progress, and resumption via ResumeHandle.
This namespace has no callable surface. Every method and class in it is internal machinery,
documented as @private and excluded from these docs; what remains visible is the data a caller
receives — Progress, ResumeHandle, HasResumeHandle — and the error classes listed below.
Uploads are driven from Gapic::ResumableUpload, which sits above this namespace and coordinates
runs against it.
Errors raised from here carry a ResumeHandle where the upload can still be continued, so the usual shape of handling one is to rescue HasResumeHandle and hand the handle back to the coordinator:
Error Types
- RequestFailedError - Transport connection failure, timeout, or retries exhausted (includes HasResumeHandle).
- DeadlineExceededError - Whole-upload timeout exceeded (includes HasResumeHandle).
- BadResponseError - Unexpected, malformed, or out-of-phase HTTP response (includes HasResumeHandle).
- UnseekableStreamError - Stream rewinding required on an unseekable stream (includes HasResumeHandle).
- StreamMismatchError - Stream content or length does not match resumed upload (includes HasResumeHandle).
- UploadRejectedError - Server explicitly rejected the upload session (final).
- UploadCancelledError - Upload session was cancelled on the server while the upload was in flight. A cancelled session cannot be resumed, so this error carries no ResumeHandle (final).
- SessionStateError - Upload session lifecycle rule violation, e.g. starting a second run while one is in flight (final).
- Any other
Gapic::Common::Errorsubclass signals a protocol implementation bug rather than a caller or server error (final).
Defined Under Namespace
Modules: HasResumeHandle Classes: BadResponseError, DeadlineExceededError, Progress, RequestFailedError, ResumeHandle, SessionStateError, StreamMismatchError, UnseekableStreamError, UploadCancelledError, UploadRejectedError