Skip to content

The 0.4.0 beta!

Compare
Choose a tag to compare
@asonix asonix released this 25 Mar 23:07

Wow! A lot has happened!

Changes:

  • Tokio ZMQ doesn't use Rc<> in the sockets anymore. Instead, they get passed around where they're needed.
  • .send(), .recv(), .stream(), and .sink() now consume the calling socket, meaning if you want to use a Stream and a Sink, you need to use the newly introduced .sink_stream() and then call .split() on it. WARNING: if you try to spawn a future with one part of the sink-stream, but not the other, you will experience a Panic. This is because the underlying datastructure used to represent the sink and stream is Send but not Sync. Sending part of the sink-stream without the other opens the possibility of simultaneous access from multiple threads. See this example for a way to avoid doing this.
  • Tokio ZMQ now uses Tokio 0.1.4 and Futures 0.2.0-beta

crate: crates.io
docs: docs.rs