pub struct ZmqFanout { /* private fields */ }Expand description
The PUB/SUB fan-out: each message reaches every subscriber whose name prefix matches.
§Examples
use ruststream_zeromq::{ZmqEndpoint, ZmqFanout};
let publisher_side = ZmqFanout::new(ZmqEndpoint::bind("tcp://0.0.0.0:5556"));
let subscriber_side = ZmqFanout::new(ZmqEndpoint::connect("tcp://events:5556"));Implementations§
Source§impl ZmqFanout
impl ZmqFanout
Sourcepub fn new(endpoint: ZmqEndpoint) -> Self
pub fn new(endpoint: ZmqEndpoint) -> Self
Records the endpoint. No I/O.
Sourcepub fn publisher(&self) -> ZmqFanoutPublisher
pub fn publisher(&self) -> ZmqFanoutPublisher
A publisher sharing this fan-out’s state; buildable before connect.
Trait Implementations§
Source§impl Broker for ZmqFanout
impl Broker for ZmqFanout
Source§impl DescribeServer for ZmqFanout
impl DescribeServer for ZmqFanout
Source§fn describe_server(&self) -> ServerSpec
fn describe_server(&self) -> ServerSpec
Returns the server coordinates for this broker.
Auto Trait Implementations§
impl !RefUnwindSafe for ZmqFanout
impl !UnwindSafe for ZmqFanout
impl Freeze for ZmqFanout
impl Send for ZmqFanout
impl Sync for ZmqFanout
impl Unpin for ZmqFanout
impl UnsafeUnpin for ZmqFanout
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