pub struct ArrowMemoryPool { /* private fields */ }Available on crate feature
arrow_buffer_pool only.Expand description
An adapter that implements Arrow’s arrow_buffer::MemoryPool trait
by wrapping a DataFusion MemoryPool.
This allows DataFusion’s memory management system to be used with Arrow’s
memory allocation APIs. Each reservation made through this pool will be
tracked using the provided MemoryConsumer, enabling DataFusion to
monitor and limit memory usage across Arrow operations.
This is useful when you want Arrow operations (such as array builders or compute kernels) to participate in DataFusion’s memory management and respect the same memory limits as DataFusion operators.
Implementations§
Source§impl ArrowMemoryPool
impl ArrowMemoryPool
Sourcepub fn new(inner: Arc<dyn MemoryPool>, consumer: MemoryConsumer) -> Self
pub fn new(inner: Arc<dyn MemoryPool>, consumer: MemoryConsumer) -> Self
Creates a new ArrowMemoryPool that wraps the given DataFusion MemoryPool
and tracks allocations under the specified MemoryConsumer.
Trait Implementations§
Source§impl Debug for ArrowMemoryPool
impl Debug for ArrowMemoryPool
Source§impl MemoryPool for ArrowMemoryPool
impl MemoryPool for ArrowMemoryPool
Auto Trait Implementations§
impl Freeze for ArrowMemoryPool
impl !RefUnwindSafe for ArrowMemoryPool
impl Send for ArrowMemoryPool
impl Sync for ArrowMemoryPool
impl Unpin for ArrowMemoryPool
impl UnsafeUnpin for ArrowMemoryPool
impl !UnwindSafe for ArrowMemoryPool
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> 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