pub struct StreamGcOutcome {
pub dry_run: bool,
pub live_base_snapshot_keys: Vec<String>,
pub collected_snapshots: Vec<String>,
pub collected_frame_objects: Vec<String>,
pub collected_bytes: u64,
pub retained_snapshots: usize,
pub base_snapshots_skipped: bool,
pub retained_frame_objects: usize,
pub spared_by_grace: usize,
}Expand description
What a gc_stream pass found — and, when dry_run was false, deleted.
The collected keys are listed rather than counted because the primary consumer is a human reading a dry run before authorizing the real one.
Fields§
§dry_run: boolEcho of StreamGcConfig::dry_run. true means nothing was deleted
and collected_* is a proposal.
live_base_snapshot_keys: Vec<String>Every snapshot key a restore could still reach, sorted. See
gc_stream’s “Liveness” section for how this is derived.
collected_snapshots: Vec<String>Superseded base snapshots, sorted.
collected_frame_objects: Vec<String>Orphaned frame objects (batch or legacy per-frame), sorted.
collected_bytes: u64Total bytes across collected_snapshots + collected_frame_objects.
retained_snapshots: usizeSnapshot objects kept — because they are live, or because the whole
snapshot half was skipped (see base_snapshots_skipped).
base_snapshots_skipped: booltrue when the prefix held no generation manifests, so this is not
provably a tier-2 sink and no base snapshot was collected.
A snapshots/ prefix with no chain over it is indistinguishable from a
plain tier-1a sink, whose older snapshots are history rather than
garbage — crate::snapshot::restore_latest takes the newest, but an
operator restoring a point in time names an older key by hand. Pruning
those is crate::dedup::gc_dedup’s keep_n decision to make, not
this sweep’s. A live tier-2 sink always has a chain, so in the steady
state this is false and the superseded bases are collected; the one
way to see it true on a real stream is a GC that lands inside
crate::tail::rebase’s manifests-deleted-frames-not-yet-written window,
where skipping one pass costs nothing.
retained_frame_objects: usizeFrame objects kept because a generation manifest still names them.
spared_by_grace: usizeObjects that were unreachable but too young to touch — the grace window did its job. A number that never falls to zero across consecutive runs means the grace is longer than the churn interval, not that the sweep is broken.
Trait Implementations§
Source§impl Clone for StreamGcOutcome
impl Clone for StreamGcOutcome
Source§fn clone(&self) -> StreamGcOutcome
fn clone(&self) -> StreamGcOutcome
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for StreamGcOutcome
impl Debug for StreamGcOutcome
Source§impl Default for StreamGcOutcome
impl Default for StreamGcOutcome
Source§fn default() -> StreamGcOutcome
fn default() -> StreamGcOutcome
impl Eq for StreamGcOutcome
Source§impl PartialEq for StreamGcOutcome
impl PartialEq for StreamGcOutcome
impl StructuralPartialEq for StreamGcOutcome
Auto Trait Implementations§
impl Freeze for StreamGcOutcome
impl RefUnwindSafe for StreamGcOutcome
impl Send for StreamGcOutcome
impl Sync for StreamGcOutcome
impl Unpin for StreamGcOutcome
impl UnsafeUnpin for StreamGcOutcome
impl UnwindSafe for StreamGcOutcome
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<K, Q> Equivalent<Q> for K
impl<K, Q> Equivalent<Q> for K
Source§fn equivalent(&self, key: &Q) -> bool
fn equivalent(&self, key: &Q) -> bool
key and return true if they are equal.impl<T> ErasedDestructor for Twhere
T: 'static,
impl<T> Fruit for T
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> ⓘ
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> ⓘ
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