pub struct DeltaIOStorageBackend { /* private fields */ }
Expand description
Wraps any object store and runs IO in it’s own runtime [EXPERIMENTAL]
Implementations§
Source§impl DeltaIOStorageBackend
impl DeltaIOStorageBackend
Sourcepub fn new(storage: ObjectStoreRef, rt_handle: Handle) -> Self
pub fn new(storage: ObjectStoreRef, rt_handle: Handle) -> Self
create wrapped object store which spawns tasks in own runtime
Sourcepub fn spawn_io_rt<F, O>(
&self,
f: F,
store: &Arc<dyn ObjectStore>,
path: Path,
) -> BoxFuture<'_, ObjectStoreResult<O>>where
F: for<'a> FnOnce(&'a Arc<dyn ObjectStore>, &'a Path) -> BoxFuture<'a, ObjectStoreResult<O>> + Send + 'static,
O: Send + 'static,
pub fn spawn_io_rt<F, O>(
&self,
f: F,
store: &Arc<dyn ObjectStore>,
path: Path,
) -> BoxFuture<'_, ObjectStoreResult<O>>where
F: for<'a> FnOnce(&'a Arc<dyn ObjectStore>, &'a Path) -> BoxFuture<'a, ObjectStoreResult<O>> + Send + 'static,
O: Send + 'static,
spawn taks on IO runtime
Sourcepub fn spawn_io_rt_from_to<F, O>(
&self,
f: F,
store: &Arc<dyn ObjectStore>,
from: Path,
to: Path,
) -> BoxFuture<'_, ObjectStoreResult<O>>where
F: for<'a> FnOnce(&'a Arc<dyn ObjectStore>, &'a Path, &'a Path) -> BoxFuture<'a, ObjectStoreResult<O>> + Send + 'static,
O: Send + 'static,
pub fn spawn_io_rt_from_to<F, O>(
&self,
f: F,
store: &Arc<dyn ObjectStore>,
from: Path,
to: Path,
) -> BoxFuture<'_, ObjectStoreResult<O>>where
F: for<'a> FnOnce(&'a Arc<dyn ObjectStore>, &'a Path, &'a Path) -> BoxFuture<'a, ObjectStoreResult<O>> + Send + 'static,
O: Send + 'static,
spawn taks on IO runtime
Trait Implementations§
Source§impl Debug for DeltaIOStorageBackend
impl Debug for DeltaIOStorageBackend
Source§impl Display for DeltaIOStorageBackend
impl Display for DeltaIOStorageBackend
Source§impl ObjectStore for DeltaIOStorageBackend
impl ObjectStore for DeltaIOStorageBackend
Source§fn put<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<PutResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<PutResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save the provided bytes to the specified location Read more
Source§fn put_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
options: PutOptions,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<PutResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
options: PutOptions,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<PutResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save the provided
payload
to location
with the given optionsSource§fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<GetResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<GetResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Return the bytes that are stored at the specified location.
Source§fn get_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
options: GetOptions,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<GetResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
options: GetOptions,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<GetResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Perform a get request with options
Source§fn get_range<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
range: Range<usize>,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Bytes>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_range<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
range: Range<usize>,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Bytes>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Return the bytes that are stored at the specified location
in the given byte range. Read more
Source§fn head<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<ObjectMeta>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn head<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<ObjectMeta>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Return the metadata for the specified location
Source§fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete the object at the specified location.
Source§fn list(
&self,
prefix: Option<&Path>,
) -> BoxStream<'_, ObjectStoreResult<ObjectMeta>>
fn list( &self, prefix: Option<&Path>, ) -> BoxStream<'_, ObjectStoreResult<ObjectMeta>>
List all the objects with the given prefix. Read more
Source§fn list_with_offset(
&self,
prefix: Option<&Path>,
offset: &Path,
) -> BoxStream<'_, ObjectStoreResult<ObjectMeta>>
fn list_with_offset( &self, prefix: Option<&Path>, offset: &Path, ) -> BoxStream<'_, ObjectStoreResult<ObjectMeta>>
List all the objects with the given prefix and a location greater than
offset
Read moreSource§fn list_with_delimiter<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: Option<&'life1 Path>,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<ListResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_with_delimiter<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: Option<&'life1 Path>,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<ListResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
List objects with the given prefix and an implementation specific
delimiter. Returns common prefixes (directories) in addition to object
metadata. Read more
Source§fn copy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn copy<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Copy an object from one path to another in the same object store. Read more
Source§fn copy_if_not_exists<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn copy_if_not_exists<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Copy an object from one path to another, only if destination is empty. Read more
Source§fn rename_if_not_exists<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn rename_if_not_exists<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Move an object from one path to another in the same object store. Read more
Source§fn put_multipart<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Box<dyn MultipartUpload>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put_multipart<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Box<dyn MultipartUpload>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Perform a multipart upload Read more
Source§fn put_multipart_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
options: PutMultipartOpts,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Box<dyn MultipartUpload>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put_multipart_opts<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
options: PutMultipartOpts,
) -> Pin<Box<dyn Future<Output = ObjectStoreResult<Box<dyn MultipartUpload>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Perform a multipart upload with options Read more
Source§fn get_ranges<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
location: &'life1 Path,
ranges: &'life2 [Range<usize>],
) -> Pin<Box<dyn Future<Output = Result<Vec<Bytes>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn get_ranges<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
location: &'life1 Path,
ranges: &'life2 [Range<usize>],
) -> Pin<Box<dyn Future<Output = Result<Vec<Bytes>, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Return the bytes that are stored at the specified location
in the given byte ranges
Source§fn delete_stream<'a>(
&'a self,
locations: Pin<Box<dyn Stream<Item = Result<Path, Error>> + Send + 'a>>,
) -> Pin<Box<dyn Stream<Item = Result<Path, Error>> + Send + 'a>>
fn delete_stream<'a>( &'a self, locations: Pin<Box<dyn Stream<Item = Result<Path, Error>> + Send + 'a>>, ) -> Pin<Box<dyn Stream<Item = Result<Path, Error>> + Send + 'a>>
Delete all the objects at the specified locations Read more
Source§fn rename<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn rename<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
from: &'life1 Path,
to: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Move an object from one path to another in the same object store. Read more
Auto Trait Implementations§
impl Freeze for DeltaIOStorageBackend
impl !RefUnwindSafe for DeltaIOStorageBackend
impl Send for DeltaIOStorageBackend
impl Sync for DeltaIOStorageBackend
impl Unpin for DeltaIOStorageBackend
impl !UnwindSafe for DeltaIOStorageBackend
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> ObjectStoreRetryExt for Twhere
T: ObjectStore + ?Sized,
impl<T> ObjectStoreRetryExt for Twhere
T: ObjectStore + ?Sized,
Source§fn put_with_retries<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
max_retries: usize,
) -> Pin<Box<dyn Future<Output = Result<PutResult>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put_with_retries<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
bytes: PutPayload,
max_retries: usize,
) -> Pin<Box<dyn Future<Output = Result<PutResult>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save the provided bytes to the specified location Read more
Source§fn delete_with_retries<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
max_retries: usize,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_with_retries<'life0, 'life1, 'async_trait>(
&'life0 self,
location: &'life1 Path,
max_retries: usize,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete the object at the specified location