mirror of
https://github.com/Noratrieb/haesli.git
synced 2026-01-16 12:45:04 +01:00
rename lol
This commit is contained in:
parent
c68cd04af7
commit
543e39f129
70 changed files with 283 additions and 266 deletions
26
haesli_core/src/message.rs
Normal file
26
haesli_core/src/message.rs
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
use std::sync::Arc;
|
||||
|
||||
use bytes::Bytes;
|
||||
use smallvec::SmallVec;
|
||||
|
||||
use crate::{connection::ContentHeader, newtype_id};
|
||||
|
||||
pub type Message = Arc<MessageInner>;
|
||||
|
||||
newtype_id!(pub MessageId);
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct MessageInner {
|
||||
pub id: MessageId,
|
||||
pub header: ContentHeader,
|
||||
pub routing: RoutingInformation,
|
||||
pub content: SmallVec<[Bytes; 1]>,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct RoutingInformation {
|
||||
pub exchange: String,
|
||||
pub routing_key: String,
|
||||
pub mandatory: bool,
|
||||
pub immediate: bool,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue