summaryrefslogtreecommitdiff
path: root/perf/c/local_thr.c
diff options
context:
space:
mode:
authormalosek <malosek@fastmq.com>2009-09-16 12:22:36 +0200
committermalosek <malosek@fastmq.com>2009-09-16 12:22:36 +0200
commit7a5db6041f4f11ed502fa7446da900509dedb00f (patch)
tree6f96beb5f647a3ac296be2f24a2f675880f6b8a7 /perf/c/local_thr.c
parent9c522dccaf0b2c8074bd96fbfb4c968f45748ba4 (diff)
added newly added socket options to all language bindings, P2P model changed to PUB/SUB for throughput tests
Diffstat (limited to 'perf/c/local_thr.c')
-rw-r--r--perf/c/local_thr.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/perf/c/local_thr.c b/perf/c/local_thr.c
index 68d9ec6..9b94330 100644
--- a/perf/c/local_thr.c
+++ b/perf/c/local_thr.c
@@ -48,9 +48,15 @@ int main (int argc, char *argv [])
ctx = zmq_init (1, 1);
assert (ctx);
- s = zmq_socket (ctx, ZMQ_P2P);
+ s = zmq_socket (ctx, ZMQ_SUB);
assert (s);
+ rc = zmq_setsockopt (s, ZMQ_SUBSCRIBE , "*", 1);
+ assert (rc == 0);
+
+ // Add your socket options here.
+ // For example ZMQ_RATE, ZMQ_RECOVERY_IVL and ZMQ_MCAST_LOOP for PGM.
+
rc = zmq_bind (s, bind_to);
assert (rc == 0);