Skip to content

Instantly share code, notes, and snippets.

diff --git a/src/xrep.cpp b/src/xrep.cpp
index 978ed0b..5fd6cbb 100644
--- a/src/xrep.cpp
+++ b/src/xrep.cpp
@@ -143,8 +143,11 @@ int zmq::xrep_t::xsend (zmq_msg_t *msg_, int flags_)
if (!more_out) {
zmq_assert (!current_out);
- // There's no such thing as prefix with no subsequent message.
- zmq_assert (msg_->flags & ZMQ_MSG_MORE);
To bridge 0MQ to SoupTCP, create a proxy that connects to SoupTCP at the frontend and publishes updates to a 0MQ network at the backend:
[[code type="textdiagram"]]
+------------+
| |
| NASDAQ |
| |
+------------+
| SoupTCP |
\------------/
Demonstrating WireAPI overflow in direct mode.
Window 1
amq_server --direct 1
Window 2
server
Window 3
client
The Internet Protocol dominates 100% of the networking market but this was not always inevitable. In 1995 Microsoft launched Windows 95, a desktop product that had no Internet but instead used a proprietary network, the Microsoft Network (MSN). The MSN and AOL walled gardens failed, as did every other attempt to capture the growing Internet in private networks. Following Internet's move onto every computer, society, economics, and even politics have gone digital to an extent that was impossible to foresee even ten years ago.
Why did the Internet dominate? It is owned by no-one, not patented, not subsidised, and represents no dominate market interest. Unlike the GSM stack, Windows, Internet looks like an orphan technology that should have been easily quashed by private interests.
The answer is exactly in this lack of centralized ownership. By 1995 Internet was already the standard for connecting the leading edge around the world. With no patents or taxes on the technology, and a clear set of interoper
<config>
<device type="forwarder|streamer|queue">
<in>
<bind addr="zmq_bind() endpoint" />
<connect addr="zmq_connect() endpoint" />
</in>
<out>
<bind addr="zmq_bind() endpoint" />
<connect addr="zmq_connect() endpoint" />
</out>
//
// Provoke assertion failure in sub.cpp:45
//
#include <zmq.h>
int main () {
void *context; // ØMQ context for our process
context = zmq_init (1);
void *s2;
//
// Provoke assertion:
// Assertion failed: !engine (session.cpp:287)
// Caused by two clients with same identity
//
#include "zhelpers.h"
void *host_routine (void *context) {
// Socket to talk to dispatcher
void *host = zmq_socket (context, ZMQ_PULL);
//
// Demonstrate identities as used by the request-reply
// pattern. Run this program by itself.
// (provokes assertion failure in xrep.cpp)
//
#include "zhelpers.h"
// Receives all message parts from socket, prints neatly
//
static void
/* testclient.c program to emit one 2-part message to testpub.c */
#include "zhelpers.h"
int main (int argc, char **argv) {
void *ctx = zmq_init (1);
assert (ctx);
void *client = zmq_socket(ctx, ZMQ_REQ);
assert (client);
/*
Reproduces freeze in 0MQ
1. Run, application hangs on zmq_close
*/
#include <zmq.h>
int main (int argc, char *argv[])
{
void *context = zmq_init (1);