pub struct SentMessage {
pub message_id: String,
pub conversation_id: String,
pub seq: i64,
pub stored: bool,
pub publication: String,
pub recipients: Vec<String>,
pub created_at: String,
}Expand description
What a send returns. stored and publication are facts about
persistence at the moment of this reply, never about anyone having read
anything.
Fields§
§message_id: String§conversation_id: String§seq: i64§stored: boolTrue when the backend that holds this body had confirmed it when this
reply was written. On a thread stored in Postgres that is the send’s
own commit, so it is always true. On a thread published through an
outbox (a team routed to JetStream) the send is accepted and recorded
first and the backend’s answer comes later, so a fresh send says
false with publication: "pending_publication". That state is not
final: it settles as stored, or as failed if the backend refuses
the body for good. While it is pending, do NOT send the message again.
Watch it settle with
get_conversation_message or get_message_receipts (stored_at),
or repeat the call with the same request_id, which returns the same
message with its current state.
publication: StringWhere the body stands with its backend right now, in the same words
a read of the message uses: stored, pending_publication
(accepted, not yet confirmed) or failed (it will not be published;
the message keeps its place and the gap stays visible). stored is
true exactly when this is "stored".
recipients: Vec<String>Who the message was addressed to, snapshotted now. A later join never enters this list.
created_at: StringTrait Implementations§
Source§impl Debug for SentMessage
impl Debug for SentMessage
Source§impl JsonSchema for SentMessage
impl JsonSchema for SentMessage
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for SentMessage
impl RefUnwindSafe for SentMessage
impl Send for SentMessage
impl Sync for SentMessage
impl Unpin for SentMessage
impl UnsafeUnpin for SentMessage
impl UnwindSafe for SentMessage
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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