pub struct ClientBuilder { /* private fields */ }
Expand description
A builder used to create all the clients for interacting with GCP services.
Note that the builder is not consumed when creating clients, and many clients can be built using the same builder. This may allow some resource re-use across the clients
Implementations§
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub async fn build_bigtable_admin_client(
&self,
config: BigtableTableAdminConfig,
project: &str,
instance_name: &str,
) -> Result<BigtableTableAdminClient<DefaultGrpcImpl>, BuildError>
Available on crate feature bigtable
only.
pub async fn build_bigtable_admin_client( &self, config: BigtableTableAdminConfig, project: &str, instance_name: &str, ) -> Result<BigtableTableAdminClient<DefaultGrpcImpl>, BuildError>
bigtable
only.Create a client for administering bigtable tables.
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub async fn build_bigtable_client(
&self,
config: BigtableConfig,
project: &str,
instance_name: &str,
) -> Result<BigtableClient<DefaultGrpcImpl>, BuildError>
Available on crate feature bigtable
only.
pub async fn build_bigtable_client( &self, config: BigtableConfig, project: &str, instance_name: &str, ) -> Result<BigtableClient<DefaultGrpcImpl>, BuildError>
bigtable
only.Create a client for connecting to bigtable
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub async fn build_pubsub_publisher(
&self,
config: PubSubConfig,
) -> Result<PublisherClient, BuildError>
Available on crate feature pubsub
only.
pub async fn build_pubsub_publisher( &self, config: PubSubConfig, ) -> Result<PublisherClient, BuildError>
pubsub
only.Create a client for publishing to the pubsub service
Sourcepub async fn build_pubsub_subscriber(
&self,
config: PubSubConfig,
) -> Result<SubscriberClient, BuildError>
Available on crate feature pubsub
only.
pub async fn build_pubsub_subscriber( &self, config: PubSubConfig, ) -> Result<SubscriberClient, BuildError>
pubsub
only.Create a client for subscribing to the pubsub service
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub fn build_storage_client(&self) -> StorageClient
Available on crate feature storage
only.
pub fn build_storage_client(&self) -> StorageClient
storage
only.Create a client for access Google Cloud Storage
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub async fn new(
config: ClientBuilderConfig,
) -> Result<Self, CreateBuilderError>
pub async fn new( config: ClientBuilderConfig, ) -> Result<Self, CreateBuilderError>
Create a new client builder using default HTTPS settings
Sourcepub async fn with_auth_connector(
config: ClientBuilderConfig,
connector_fn: impl FnOnce() -> HttpsConnector<HttpConnector>,
) -> Result<Self, CreateBuilderError>
pub async fn with_auth_connector( config: ClientBuilderConfig, connector_fn: impl FnOnce() -> HttpsConnector<HttpConnector>, ) -> Result<Self, CreateBuilderError>
Create a new client builder using the given connector for authentication requests
Auto Trait Implementations§
impl Freeze for ClientBuilder
impl !RefUnwindSafe for ClientBuilder
impl Send for ClientBuilder
impl Sync for ClientBuilder
impl Unpin for ClientBuilder
impl !UnwindSafe for ClientBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request