pub struct PubsubMessage {
pub attributes: Option<HashMap<String, String>>,
pub data: Option<Vec<u8>>,
pub message_id: Option<String>,
pub publish_time: Option<DateTime<Utc>>,
}Expand description
A message data and its attributes. The message payload must not be empty; it must contain either a non-empty data field, or at least one attribute.
This type is not used in any activity, and only used as part of another schema.
Fields§
§attributes: Option<HashMap<String, String>>Optional attributes for this message.
data: Option<Vec<u8>>The message payload. For JSON requests, the value of this field must be base64-encoded.
message_id: Option<String>ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a PubsubMessage via a Pull call or a push delivery. It must not be populated by the publisher in a Publish call.
publish_time: Option<DateTime<Utc>>The time at which the message was published, populated by the server when it receives the Publish call. It must not be populated by the publisher in a Publish call.
Trait Implementations§
Source§impl Clone for PubsubMessage
impl Clone for PubsubMessage
Source§fn clone(&self) -> PubsubMessage
fn clone(&self) -> PubsubMessage
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more