pub struct S3Backend<IO> { /* private fields */ }
Implementations§
Trait Implementations§
Source§impl<IO> Backend for S3Backend<IO>where
IO: Io,
impl<IO> Backend for S3Backend<IO>where
IO: Io,
Source§async fn store(
&self,
config: &Self::Config,
meta: SegmentMeta,
segment_data: impl FileExt,
segment_index: Vec<u8>,
) -> Result<()>
async fn store( &self, config: &Self::Config, meta: SegmentMeta, segment_data: impl FileExt, segment_index: Vec<u8>, ) -> Result<()>
Store
segment_data
with its associated meta
Source§async fn meta(
&self,
config: &Self::Config,
namespace: &NamespaceName,
) -> Result<DbMeta>
async fn meta( &self, config: &Self::Config, namespace: &NamespaceName, ) -> Result<DbMeta>
Fetch meta for
namespace
Source§fn default_config(&self) -> Self::Config
fn default_config(&self) -> Self::Config
Returns the default configuration for this storage
async fn restore( &self, config: &Self::Config, namespace: &NamespaceName, restore_options: RestoreOptions, dest: impl FileExt, ) -> Result<()>
async fn find_segment( &self, config: &Self::Config, namespace: &NamespaceName, req: FindSegmentReq, ) -> Result<SegmentKey>
async fn fetch_segment_index( &self, config: &Self::Config, namespace: &NamespaceName, key: &SegmentKey, ) -> Result<Map<Arc<[u8]>>>
Source§async fn fetch_segment_data_to_file(
&self,
config: &Self::Config,
namespace: &NamespaceName,
key: &SegmentKey,
file: &impl FileExt,
) -> Result<CompactedSegmentDataHeader>
async fn fetch_segment_data_to_file( &self, config: &Self::Config, namespace: &NamespaceName, key: &SegmentKey, file: &impl FileExt, ) -> Result<CompactedSegmentDataHeader>
Fetch a segment for
namespace
containing frame_no
, and writes it to dest
.async fn fetch_segment_data( self: Arc<Self>, config: Self::Config, namespace: NamespaceName, key: SegmentKey, ) -> Result<impl FileExt>
fn list_segments<'a>( &'a self, config: Self::Config, namespace: &'a NamespaceName, until: u64, ) -> impl Stream<Item = Result<SegmentInfo>> + 'a
Auto Trait Implementations§
impl<IO> Freeze for S3Backend<IO>where
IO: Freeze,
impl<IO> !RefUnwindSafe for S3Backend<IO>
impl<IO> Send for S3Backend<IO>where
IO: Send,
impl<IO> Sync for S3Backend<IO>where
IO: Sync,
impl<IO> Unpin for S3Backend<IO>where
IO: Unpin,
impl<IO> !UnwindSafe for S3Backend<IO>
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 moreCreates a shared type from an unshared type.