pub struct Outbox { /* private fields */ }Expand description
File-backed outbox under the existing notifications write grant.
Implementations§
Source§impl Outbox
impl Outbox
Sourcepub fn file(
&self,
task: &Task,
run: Option<String>,
source: String,
summary: &str,
detail: &str,
) -> Result<Inquiry>
pub fn file( &self, task: &Task, run: Option<String>, source: String, summary: &str, detail: &str, ) -> Result<Inquiry>
File one content-distinct inquiry. An unchanged producer replay retains its receipt; independent inquiries need distinct occurrence identifiers.
Sourcepub fn file_for_occurrence(
&self,
task: &Task,
run: Option<String>,
source: String,
request: &str,
summary: &str,
detail: &str,
) -> Result<Inquiry>
pub fn file_for_occurrence( &self, task: &Task, run: Option<String>, source: String, request: &str, summary: &str, detail: &str, ) -> Result<Inquiry>
File or replay an explicit producer occurrence independently of prose. Use a new key for each separate inquiry, including identical wording.
Sourcepub fn get(&self, id: &str) -> Result<Inquiry>
pub fn get(&self, id: &str) -> Result<Inquiry>
Read one delivery without consulting legacy question records.
Sourcepub fn enqueue(&self, inquiry: Inquiry) -> Result<Inquiry>
pub fn enqueue(&self, inquiry: Inquiry) -> Result<Inquiry>
Persist before delivery. Retries retain the original input and receipt.
Sourcepub fn deliver(&self, queue: &Queue, talks: &Talks, id: &str) -> Result<String>
pub fn deliver(&self, queue: &Queue, talks: &Talks, id: &str) -> Result<String>
Deliver under a per-inquiry lease, releasing the task lock before any conversation operation. The transcript key repairs a lost final receipt.
Sourcepub fn list(&self) -> Result<Vec<Inquiry>>
pub fn list(&self) -> Result<Vec<Inquiry>>
Read all durable inquiries, including completed decision history.
Sourcepub fn list_readable(&self) -> Result<(Vec<Inquiry>, usize)>
pub fn list_readable(&self) -> Result<(Vec<Inquiry>, usize)>
一覧表示用の同一走査で、正常な記録と読めない記録の件数を返す。 実行系の厳密な list / pending のエラー処理は変更しない。
Sourcepub fn update_decision(
&self,
id: &str,
change: impl FnOnce(&mut Decision) -> Result<bool>,
) -> Result<()>
pub fn update_decision( &self, id: &str, change: impl FnOnce(&mut Decision) -> Result<bool>, ) -> Result<()>
Change only the decision lifecycle under the same lease as delivery. Returning false avoids rewriting a receipt on every scheduler lap.
Sourcepub fn settle(
&self,
id: &str,
chat: &str,
reason: &str,
replacement: Option<&str>,
) -> Result<()>
pub fn settle( &self, id: &str, chat: &str, reason: &str, replacement: Option<&str>, ) -> Result<()>
Explicit settlement belongs to the owning task chat. Replacement must already exist and have the same task/repository; it executes nothing. Undelivered ownerless imports may be settled from any authorized chat without assigning that chat or inventing a task association. Accepted legacy choices support explicit owner confirmation of no remaining effect; native command uncertainty still requires its receipt.
Trait Implementations§
Auto Trait Implementations§
impl Forget for Outbox
impl Freeze for Outbox
impl RefUnwindSafe for Outbox
impl Send for Outbox
impl Sync for Outbox
impl Unpin for Outbox
impl UnsafeUnpin for Outbox
impl UnwindSafe for Outbox
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