pub struct OutputBuffer {
pub repo: String,
pub session: String,
pub task_id: String,
pub last_content: String,
pub last_len: usize,
pub last_hash: Option<[u8; 32]>,
pub last_capture: DateTime<Utc>,
pub seen_alive: bool,
pub registered_at: DateTime<Utc>,
pub has_output: bool,
pub generation: u64,
}Expand description
Buffer for tracking session output state.
Fields§
§repo: StringRepo slug (owner/repo) that owns this session.
session: StringThe tmux session name (e.g., “orch-myproject-42”)
task_id: StringThe task ID this session belongs to
last_content: StringContent from the last capture
last_len: usizeByte length of the last capture
last_hash: Option<[u8; 32]>Hash of the last capture (for dedup)
last_capture: DateTime<Utc>When the last capture occurred
seen_alive: boolWhether the session has been seen alive at least once (i.e., capture_pane
succeeded at least once). Prevents firing “session ended” for sessions that
were registered before the tmux session was actually created.
Also used by silence detection: a seen-alive session with no output is only
treated as silent if the tmux session is currently dead (silent exit-0).
registered_at: DateTime<Utc>When this session was registered for capture.
has_output: boolWhether the agent has produced any meaningful output since session start. Used for silence detection: only agents that never produced output are considered silent. Agents that produced output then go quiet are NOT killed (they may be running long tool calls with sparse output).
generation: u64Generation counter incremented on each registration for this session_key. Used to detect when a session has been re-registered (e.g., after retry) so that stale snapshots from previous generations don’t incorrectly trigger final/unregister side effects.
Trait Implementations§
Source§impl Clone for OutputBuffer
impl Clone for OutputBuffer
Auto Trait Implementations§
impl Freeze for OutputBuffer
impl RefUnwindSafe for OutputBuffer
impl Send for OutputBuffer
impl Sync for OutputBuffer
impl Unpin for OutputBuffer
impl UnsafeUnpin for OutputBuffer
impl UnwindSafe for OutputBuffer
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> 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