[zeromq-dev] HWM ignored on inproc connection

Martin Sustrik sustrik at 250bpm.com
Tue Jan 4 15:43:00 CET 2011


On 01/04/2011 03:34 PM, Douglas Creager wrote:

>> Ok. That would require passing each peer's HWM to the other peer.
>> So that both can compute and use sum HWM instead of the original
>> local HWM.
>>
>> In short:
>>
>> 1. There's ctx_t::register_endpoint function which register inproc
>> endpoint with the context. We can store bind()er's HWM there.
>>
>> 2. When connect()er retrieves the ednpoint, it would get bind()er's
>> HWM along with it, it will add the two HWMs and initialise the
>> newly created pipe accordingly.
>
> Oh, I though this would just be for inproc connections.  As in, the
> total size of all buffers should be SNDHWM + RCVHWM.  For TCP, there
> are buffers on either side of the network connection, and so you get
> this by having one side create a SNDHWM buffer, and the other create
> a RCVHWM buffer.  It's only in the inproc connection — where there's
> only a single buffer — where you'd have to add together the values to
> get the correct buffer size.

Agreed. I haven't suggested otherwise btw.

Martin



More information about the zeromq-dev mailing list