Hi Michael,

> I've thought about this same issue before, but I'd like to reference
> counted pointers in inproc messages so that I can send the same message
> to multiple actors without having to duplicate the message data (very
> large at times). Does anyone have any ideas on how to accomplish this?

0MQ already does that. When you send a message to PUB socket, the 
messages that arrive at inproc-connected SUB sockets share the same data 
buffer.

If you want to manage the refcounting manually, use zmq_msg_copy(). It 
will create a new reference to existing buffer, rather than copying it.

Martin
_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to