inject dependency on haesli_messaging into haesli_transport to simplify dependency graph

This commit is contained in:
nora 2022-03-20 21:19:43 +01:00
parent 92e3ac486b
commit b4ecb6b5d4
8 changed files with 47 additions and 16 deletions

View file

@ -7,7 +7,7 @@ pub enum TopicSegment {
Word(String),
SingleWildcard,
MultiWildcard,
}
}
#[derive(Debug)]
pub enum ExchangeType {
@ -16,7 +16,9 @@ pub enum ExchangeType {
/// Always routes the message to a queue
Fanout { bindings: Vec<Queue> },
/// Routes a message to a queue if the routing key matches the pattern
Topic { bindings: Vec<(Vec<TopicSegment>, Queue)> },
Topic {
bindings: Vec<(Vec<TopicSegment>, Queue)>,
},
/// Is bound with a table of headers and values, and matches if the message headers
/// match up with the binding headers
///