Class ResumableUploadCallable<RequestT,ResponseT> (2.87.0)

public abstract class ResumableUploadCallable<RequestT,ResponseT>

A ResumableUploadCallable is an API-transport-independent wrapper for the Resumable Upload protocol. Operates directly on the request object and input stream payload.

Inheritance

java.lang.Object > ResumableUploadCallable<RequestT,ResponseT>

Type Parameters

Name Description
RequestT
ResponseT

Constructors

ResumableUploadCallable()

protected ResumableUploadCallable()

Methods

futureCall(RequestT request, InputStreamSupplier payload, @Nullable ApiCallContext context, @Nullable ResumableUploadOptions options)

public abstract ResumableUploadFuture<ResponseT> futureCall(RequestT request, InputStreamSupplier payload, @Nullable ApiCallContext context, @Nullable ResumableUploadOptions options)

Performs a new resumable upload asynchronously with call context and options overrides.

Streams from the provided payload are consumed asynchronously by the returned ResumableUploadFuture and will be closed automatically upon completion, failure, or cancellation.

Parameters
Name Description
request RequestT

the request message

payload InputStreamSupplier

supplier of the data payload input stream to upload and close

context @org.jspecify.annotations.Nullable com.google.api.gax.rpc.ApiCallContext

call context overrides; may be null

options @org.jspecify.annotations.Nullable com.google.api.gax.rpc.ResumableUploadOptions

request-level upload options overrides; may be null

Returns
Type Description
ResumableUploadFuture<ResponseT>

future for tracking and controlling the upload

futureCall(RequestT request, InputStreamSupplier payload, @Nullable ResumableUploadOptions options)

public ResumableUploadFuture<ResponseT> futureCall(RequestT request, InputStreamSupplier payload, @Nullable ResumableUploadOptions options)

Performs a new resumable upload asynchronously with options overrides and default call context.

Streams from the provided payload are consumed asynchronously by the returned ResumableUploadFuture and will be closed automatically upon completion, failure, or cancellation.

Parameters
Name Description
request RequestT

the request message

payload InputStreamSupplier

supplier of the data payload input stream to upload and close

options @org.jspecify.annotations.Nullable com.google.api.gax.rpc.ResumableUploadOptions

request-level upload options overrides; may be null

Returns
Type Description
ResumableUploadFuture<ResponseT>

future for tracking and controlling the upload

resumeCall(String sessionUrl, InputStreamSupplier payload, @Nullable ResumableUploadOptions options)

public abstract ResumableUploadFuture<ResponseT> resumeCall(String sessionUrl, InputStreamSupplier payload, @Nullable ResumableUploadOptions options)

Resumes an existing resumable upload session asynchronously using a saved session URL.

Streams from the provided payload are consumed asynchronously by the returned ResumableUploadFuture and will be closed automatically upon completion, failure, or cancellation.

Parameters
Name Description
sessionUrl String

the upload session URL

payload InputStreamSupplier

supplier of the data payload input stream to upload and close

options @org.jspecify.annotations.Nullable com.google.api.gax.rpc.ResumableUploadOptions

upload options overrides; may be null

Returns
Type Description
ResumableUploadFuture<ResponseT>

future for tracking and controlling the upload