pub struct ClickHouseConnectionPool { /* private fields */ }
Expand description
A wrapper around a clickhouse_arrow::ConnectionPool<ArrowFormat>
Implementations§
Source§impl ClickHouseConnectionPool
impl ClickHouseConnectionPool
Sourcepub fn new(identifier: impl Into<String>, pool: ArrowPool) -> Self
pub fn new(identifier: impl Into<String>, pool: ArrowPool) -> Self
Create a new ClickHouse
connection pool for use in DataFusion
. The identifier is used in
the case of federation to determine if queries can be pushed down across two pools
Sourcepub async fn from_pool_builder(
builder: ArrowConnectionPoolBuilder,
) -> Result<Self>
pub async fn from_pool_builder( builder: ArrowConnectionPoolBuilder, ) -> Result<Self>
Create a new ClickHouse
connection pool from a builder.
§Errors
- Returns an error if the connection pool cannot be created.
pub fn join_push_down(&self) -> JoinPushDown
Source§impl ClickHouseConnectionPool
impl ClickHouseConnectionPool
Sourcepub async fn connect(&self) -> Result<ClickHouseConnection<'_>>
pub async fn connect(&self) -> Result<ClickHouseConnection<'_>>
Get a managed ArrowPoolConnection
wrapped in a ClickHouseConnection
§Errors
- Returns an error if the connection cannot be established.
Sourcepub async fn connect_static(&self) -> Result<ClickHouseConnection<'static>>
pub async fn connect_static(&self) -> Result<ClickHouseConnection<'static>>
Get a managed static ArrowPoolConnection
wrapped in a ClickHouseConnection
§Errors
- Returns an error if the connection cannot be established.
Trait Implementations§
Source§impl Clone for ClickHouseConnectionPool
impl Clone for ClickHouseConnectionPool
Source§fn clone(&self) -> ClickHouseConnectionPool
fn clone(&self) -> ClickHouseConnectionPool
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for ClickHouseConnectionPool
impl !RefUnwindSafe for ClickHouseConnectionPool
impl Send for ClickHouseConnectionPool
impl Sync for ClickHouseConnectionPool
impl Unpin for ClickHouseConnectionPool
impl !UnwindSafe for ClickHouseConnectionPool
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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 more