Struct async_nats::message::Message
source · pub struct Message {
pub subject: String,
pub reply: Option<String>,
pub payload: Bytes,
pub headers: Option<HeaderMap>,
pub status: Option<StatusCode>,
pub description: Option<String>,
pub length: usize,
}Expand description
A Core NATS message.
Fields§
§subject: StringSubject to which message is published to.
reply: Option<String>Optional reply subject to which response can be published by crate::Subscriber. Used for request-response pattern with crate::Client::request.
payload: BytesPayload of the message. Can be any arbitrary data format.
headers: Option<HeaderMap>Optional headers.
status: Option<StatusCode>Optional Status of the message. Used mostly for internal handling.
description: Option<String>Optional status description.
length: usize