pub struct ZmqQueue { /* private fields */ }Expand description
The PUSH/PULL queue: each message reaches one of the competing consumers.
§Examples
use ruststream_zeromq::{ZmqEndpoint, ZmqQueue};
let consumer = ZmqQueue::new(ZmqEndpoint::bind("tcp://0.0.0.0:5555"));
let producer = ZmqQueue::new(ZmqEndpoint::connect("tcp://worker:5555"));Implementations§
Source§impl ZmqQueue
impl ZmqQueue
Sourcepub fn new(endpoint: ZmqEndpoint) -> Self
pub fn new(endpoint: ZmqEndpoint) -> Self
Records the endpoint. No I/O.
Sourcepub fn publisher(&self) -> ZmqQueuePublisher
pub fn publisher(&self) -> ZmqQueuePublisher
A publisher sharing this queue’s state; buildable before connect.
Trait Implementations§
Source§impl Broker for ZmqQueue
impl Broker for ZmqQueue
Source§impl DescribeServer for ZmqQueue
impl DescribeServer for ZmqQueue
Source§fn describe_server(&self) -> ServerSpec
fn describe_server(&self) -> ServerSpec
Returns the server coordinates for this broker.
Auto Trait Implementations§
impl !RefUnwindSafe for ZmqQueue
impl !UnwindSafe for ZmqQueue
impl Freeze for ZmqQueue
impl Send for ZmqQueue
impl Sync for ZmqQueue
impl Unpin for ZmqQueue
impl UnsafeUnpin for ZmqQueue
Blanket Implementations§
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