pub struct PublishOptions {
pub persistent: bool,
pub message_id: Option<String>,
pub correlation_id: Option<String>,
pub reply_to: Option<String>,
pub ttl: Option<Duration>,
pub priority: Option<u8>,
pub headers: HashMap<String, AMQPValue>,
pub auto_declare_queue: bool,
pub auto_declare_exchange: bool,
pub queue_options: CustomQueueDeclareOptions,
pub exchange_options: CustomExchangeDeclareOptions,
}Expand description
Options for publishing messages
Fields§
§persistent: boolWhether the message should be persistent
message_id: Option<String>Message ID
correlation_id: Option<String>Correlation ID for request-response patterns
reply_to: Option<String>Reply-to queue for RPC patterns
ttl: Option<Duration>Message Time To Live
priority: Option<u8>Message priority (0-255)
headers: HashMap<String, AMQPValue>Custom headers
auto_declare_queue: boolAuto-declare queue before publishing
auto_declare_exchange: boolAuto-declare exchange before publishing
queue_options: CustomQueueDeclareOptionsQueue declaration options
exchange_options: CustomExchangeDeclareOptionsExchange declaration options
Implementations§
Source§impl PublishOptions
impl PublishOptions
Sourcepub fn builder() -> PublishOptionsBuilder
pub fn builder() -> PublishOptionsBuilder
Create a new publish options builder
Trait Implementations§
Source§impl Clone for PublishOptions
impl Clone for PublishOptions
Source§fn clone(&self) -> PublishOptions
fn clone(&self) -> PublishOptions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PublishOptions
impl Debug for PublishOptions
Auto Trait Implementations§
impl Freeze for PublishOptions
impl RefUnwindSafe for PublishOptions
impl Send for PublishOptions
impl Sync for PublishOptions
impl Unpin for PublishOptions
impl UnwindSafe for PublishOptions
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Mutably borrows from an owned value. Read more