pub struct FlightClientPool { /* private fields */ }Expand description
Connection pool for managing multiple Flight clients.
Implementations§
Source§impl FlightClientPool
impl FlightClientPool
Sourcepub async fn add_client(&mut self, address: String) -> Result<()>
pub async fn add_client(&mut self, address: String) -> Result<()>
Add a client to the pool.
Sourcepub fn get_client(&mut self) -> Result<&mut FlightClient>
pub fn get_client(&mut self) -> Result<&mut FlightClient>
Get a client from the pool (round-robin).
Sourcepub async fn health_check_all(&mut self) -> Result<Vec<bool>>
pub async fn health_check_all(&mut self) -> Result<Vec<bool>>
Check health of all clients.
Auto Trait Implementations§
impl Freeze for FlightClientPool
impl !RefUnwindSafe for FlightClientPool
impl Send for FlightClientPool
impl Sync for FlightClientPool
impl Unpin for FlightClientPool
impl UnsafeUnpin for FlightClientPool
impl !UnwindSafe for FlightClientPool
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> 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