Class ConnectionWorkerPool (2.21.0)

public class ConnectionWorkerPool

Inheritance

java.lang.Object > ConnectionWorkerPool

Static Methods

setOptions(ConnectionWorkerPool.Settings settings)

public static void setOptions(ConnectionWorkerPool.Settings settings)

Sets static connection pool options.

Note: this method should be triggered prior to the construction of connection pool.

Parameter
NameDescription
settingsConnectionWorkerPool.Settings

Constructors

ConnectionWorkerPool(long maxInflightRequests, long maxInflightBytes, FlowController.LimitExceededBehavior limitExceededBehavior, String traceId, BigQueryWriteClient client, boolean ownsBigQueryWriteClient)

public ConnectionWorkerPool(long maxInflightRequests, long maxInflightBytes, FlowController.LimitExceededBehavior limitExceededBehavior, String traceId, BigQueryWriteClient client, boolean ownsBigQueryWriteClient)
Parameters
NameDescription
maxInflightRequestslong
maxInflightByteslong
limitExceededBehaviorLimitExceededBehavior
traceIdString
clientBigQueryWriteClient
ownsBigQueryWriteClientboolean

Methods

append(StreamWriter streamWriter, ProtoRows rows)

public ApiFuture<AppendRowsResponse> append(StreamWriter streamWriter, ProtoRows rows)

Distributes the writing of a message to an underlying connection.

Parameters
NameDescription
streamWriterStreamWriter
rowsProtoRows
Returns
TypeDescription
ApiFuture<AppendRowsResponse>

append(StreamWriter streamWriter, ProtoRows rows, long offset)

public ApiFuture<AppendRowsResponse> append(StreamWriter streamWriter, ProtoRows rows, long offset)

Distributes the writing of a message to an underlying connection.

Parameters
NameDescription
streamWriterStreamWriter
rowsProtoRows
offsetlong
Returns
TypeDescription
ApiFuture<AppendRowsResponse>

close(StreamWriter streamWriter)

public void close(StreamWriter streamWriter)

Close the stream writer. Shut down all resources.

Parameter
NameDescription
streamWriterStreamWriter