pub struct TrustedScratch { /* private fields */ }Expand description
Validated trusted-service scratch root. It owns an open descriptor so the validated root remains the authority for attempt creation.
Implementations§
Source§impl TrustedScratch
impl TrustedScratch
pub fn open<'a>( root: &Path, filesystem_lake_locations: impl IntoIterator<Item = &'a Path>, ) -> Result<Self, ScratchError>
Sourcepub fn create_session_attempt(
&self,
identifier: ScratchAttemptId,
) -> Result<ScratchAttempt, ScratchError>
pub fn create_session_attempt( &self, identifier: ScratchAttemptId, ) -> Result<ScratchAttempt, ScratchError>
Session-local DuckDB spill is distinct from durable Dataset attempt scratch. A retained OS lease lets a restarted runtime reap only stopped Sessions.
Sourcepub fn reap_abandoned_sessions(&self) -> Result<(), ScratchError>
pub fn reap_abandoned_sessions(&self) -> Result<(), ScratchError>
Reaps abandoned Session spill only. Dataset attempt directories have no Session marker and must use shared durable attempt recovery, even when no public operation exists. A live lease always prevents deletion.
pub fn create_attempt( &self, identifier: ScratchAttemptId, ) -> Result<ScratchAttempt, ScratchError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TrustedScratch
impl RefUnwindSafe for TrustedScratch
impl Send for TrustedScratch
impl Sync for TrustedScratch
impl Unpin for TrustedScratch
impl UnsafeUnpin for TrustedScratch
impl UnwindSafe for TrustedScratch
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