Class BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> (2.36.0)

public static class BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> extends UnaryCallSettings.Builder<RequestT,ResponseT>

A base builder class for BatchingCallSettings. See the class documentation of BatchingCallSettings for a description of the different values that can be set.

Inheritance

java.lang.Object > UnaryCallSettings.Builder > BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT>

Type Parameters

NameDescription
ElementT
ElementResultT
RequestT
ResponseT

Methods

build()

public BatchingCallSettings<ElementT,ElementResultT,RequestT,ResponseT> build()

Builds the BatchingCallSettings object with provided configuration.

Returns
TypeDescription
BatchingCallSettings<ElementT,ElementResultT,RequestT,ResponseT>
Overrides

getBatchingSettings()

public BatchingSettings getBatchingSettings()

Returns the BatchingSettings.

Returns
TypeDescription
BatchingSettings

setBatchingSettings(BatchingSettings batchingSettings)

public BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> setBatchingSettings(BatchingSettings batchingSettings)

Sets the batching settings with various thresholds.

Parameter
NameDescription
batchingSettingsBatchingSettings
Returns
TypeDescription
Builder<ElementT,ElementResultT,RequestT,ResponseT>

setRetrySettings(RetrySettings retrySettings)

public BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> setRetrySettings(RetrySettings retrySettings)

Sets the RetrySettings values for each retry attempts.

Parameter
NameDescription
retrySettingsRetrySettings
Returns
TypeDescription
Builder<ElementT,ElementResultT,RequestT,ResponseT>
Overrides

setRetryableCodes(StatusCode.Code[] codes)

public BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> setRetryableCodes(StatusCode.Code[] codes)

Sets the rpc failure code, for which retries should be performed.

Parameter
NameDescription
codesCode[]
Returns
TypeDescription
Builder<ElementT,ElementResultT,RequestT,ResponseT>
Overrides

setRetryableCodes(Set<StatusCode.Code> retryableCodes)

public BatchingCallSettings.Builder<ElementT,ElementResultT,RequestT,ResponseT> setRetryableCodes(Set<StatusCode.Code> retryableCodes)

Sets the rpc failure code, for which retries should be performed.

Parameter
NameDescription
retryableCodesSet<Code>
Returns
TypeDescription
Builder<ElementT,ElementResultT,RequestT,ResponseT>
Overrides