Class DataClient (2.21.0)

Connects to Cloud Bigtable's data manipulation APIs.

This class is used by the Cloud Bigtable wrappers to access Cloud Bigtable. Multiple bigtable::Table objects may share a connection via a single DataClient object. The DataClient object is configured at construction time, this configuration includes the credentials, access endpoints, default timeouts, and other gRPC configuration options. This is an interface class because it is also used as a dependency injection point in some of the tests.

Cost

Applications should avoid unnecessarily creating new objects of type DataClient. Creating a new object of this type typically requires connecting to the Cloud Bigtable servers, and performing the authentication workflows with Google Cloud Platform. These operations can take many milliseconds, therefore applications should try to reuse the same DataClient instances when possible.

google::cloud::bigtable::DataConnection is the preferred way to communicate with the Bigtable Data API. To migrate existing code, see Migrating from DataClient.

Functions

MutateRow(grpc::ClientContext *, google::bigtable::v2::MutateRowRequest const &, google::bigtable::v2::MutateRowResponse *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::MutateRowRequest const &
response google::bigtable::v2::MutateRowResponse *
Returns
TypeDescription
grpc::Status

AsyncMutateRow(grpc::ClientContext *, google::bigtable::v2::MutateRowRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::MutateRowRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr< grpc::ClientAsyncResponseReaderInterface< google::bigtable::v2::MutateRowResponse > >

CheckAndMutateRow(grpc::ClientContext *, google::bigtable::v2::CheckAndMutateRowRequest const &, google::bigtable::v2::CheckAndMutateRowResponse *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::CheckAndMutateRowRequest const &
response google::bigtable::v2::CheckAndMutateRowResponse *
Returns
TypeDescription
grpc::Status

AsyncCheckAndMutateRow(grpc::ClientContext *, google::bigtable::v2::CheckAndMutateRowRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::CheckAndMutateRowRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr< grpc::ClientAsyncResponseReaderInterface< google::bigtable::v2::CheckAndMutateRowResponse > >

ReadModifyWriteRow(grpc::ClientContext *, google::bigtable::v2::ReadModifyWriteRowRequest const &, google::bigtable::v2::ReadModifyWriteRowResponse *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::ReadModifyWriteRowRequest const &
response google::bigtable::v2::ReadModifyWriteRowResponse *
Returns
TypeDescription
grpc::Status

AsyncReadModifyWriteRow(grpc::ClientContext *, google::bigtable::v2::ReadModifyWriteRowRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::ReadModifyWriteRowRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr< grpc::ClientAsyncResponseReaderInterface< google::bigtable::v2::ReadModifyWriteRowResponse > >

ReadRows(grpc::ClientContext *, google::bigtable::v2::ReadRowsRequest const &)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::ReadRowsRequest const &
Returns
TypeDescription
std::unique_ptr< grpc::ClientReaderInterface< google::bigtable::v2::ReadRowsResponse > >

AsyncReadRows(grpc::ClientContext *, google::bigtable::v2::ReadRowsRequest const &, grpc::CompletionQueue *, void *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::ReadRowsRequest const &
cq grpc::CompletionQueue *
tag void *
Returns
TypeDescription
std::unique_ptr< grpc::ClientAsyncReaderInterface< google::bigtable::v2::ReadRowsResponse > >

PrepareAsyncReadRows(::grpc::ClientContext *, google::bigtable::v2::ReadRowsRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context ::grpc::ClientContext *
request google::bigtable::v2::ReadRowsRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr<::grpc::ClientAsyncReaderInterface< google::bigtable::v2::ReadRowsResponse > >

SampleRowKeys(grpc::ClientContext *, google::bigtable::v2::SampleRowKeysRequest const &)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::SampleRowKeysRequest const &
Returns
TypeDescription
std::unique_ptr< grpc::ClientReaderInterface< google::bigtable::v2::SampleRowKeysResponse > >

AsyncSampleRowKeys(grpc::ClientContext *, google::bigtable::v2::SampleRowKeysRequest const &, grpc::CompletionQueue *, void *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::SampleRowKeysRequest const &
cq grpc::CompletionQueue *
tag void *
Returns
TypeDescription
std::unique_ptr<::grpc::ClientAsyncReaderInterface< google::bigtable::v2::SampleRowKeysResponse > >

virtual PrepareAsyncSampleRowKeys(grpc::ClientContext *, google::bigtable::v2::SampleRowKeysRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::SampleRowKeysRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr<::grpc::ClientAsyncReaderInterface< google::bigtable::v2::SampleRowKeysResponse > >

MutateRows(grpc::ClientContext *, google::bigtable::v2::MutateRowsRequest const &)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::MutateRowsRequest const &
Returns
TypeDescription
std::unique_ptr< grpc::ClientReaderInterface< google::bigtable::v2::MutateRowsResponse > >

AsyncMutateRows(::grpc::ClientContext *, google::bigtable::v2::MutateRowsRequest const &, grpc::CompletionQueue *, void *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context ::grpc::ClientContext *
request google::bigtable::v2::MutateRowsRequest const &
cq grpc::CompletionQueue *
tag void *
Returns
TypeDescription
std::unique_ptr<::grpc::ClientAsyncReaderInterface< google::bigtable::v2::MutateRowsResponse > >

PrepareAsyncMutateRows(grpc::ClientContext *, google::bigtable::v2::MutateRowsRequest const &, grpc::CompletionQueue *)

the google.bigtable.v2.Bigtable wrappers.

Parameters
NameDescription
context grpc::ClientContext *
request google::bigtable::v2::MutateRowsRequest const &
cq grpc::CompletionQueue *
Returns
TypeDescription
std::unique_ptr<::grpc::ClientAsyncReaderInterface< google::bigtable::v2::MutateRowsResponse > >

project_id() const

Returns
TypeDescription
std::string const &

instance_id() const

Returns
TypeDescription
std::string const &

Channel()

Return a new channel to handle admin operations.

Intended to access rarely used services in the same endpoints as the Bigtable admin interfaces, for example, the google.longrunning.Operations.

Returns
TypeDescription
std::shared_ptr< grpc::Channel >

reset()

Reset and create new Channels.

Returns
TypeDescription
void

BackgroundThreadsFactory()

The thread factory this client was created with.

Returns
TypeDescription
google::cloud::BackgroundThreadsFactory