Skip to content
This repository was archived by the owner on Jul 8, 2022. It is now read-only.

Set the ZMQ Receive Buffer High Water Mark only if it changes (#444) #445

Merged
merged 2 commits into from
May 4, 2018

Conversation

bourtemb
Copy link
Member

This is to reduce the impact of a bug present in ZMQ 4.2.0 and ZMQ 4.2.1 which led to a bad lwm and hwm calculation when ZMQ_RCVHWM was set after the bind of the socket. See #444 for more details

@t-b
Copy link
Collaborator

t-b commented Apr 10, 2018

@bourtemb Do you know the upstream commit ID where the bug is fixed?

@tango-controls-bot
Copy link
Collaborator

Matej (@mkomel) was talking about the following commit: zeromq/libzmq@edc770d in #444

@t-b
Copy link
Collaborator

t-b commented Apr 18, 2018

@tango-tickets-migrator Thx.

@bourtemb bourtemb requested a review from Ingvord May 3, 2018 15:55
Copy link
Member

@Ingvord Ingvord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would extract the whole snippet to a method and move comment to method's documentation:

/**
     * Set the ZMQ Receive Buffer High Water Mark only if it changes
     * This is to reduce the impact of a bug present in ZMQ 4.2.0 and ZMQ 4.2.1
     * which leads to a bad lwm and hwm calculation when ZMQ_RCVHWM is set after
     * the bind of the socket. See cppTango#444 for more details
     * 
     * @param ...
     * 
     */
     void set_sockect_hwm(size_t hwm, socket* socket /*etc*/)

When extracting method please prefer passing arguments rather than class fields (whenever possible) - this simplifies further refactorings

bourtemb added 2 commits May 4, 2018 09:48
…controls#444)

This is to reduce the impact of a bug present in ZMQ 4.2.0 and ZMQ 4.2.1
which led to a bad lwm and hwm calculation when ZMQ_RCVHWM was set after
the bind of the socket. See cppTango#444 for more details
@bourtemb bourtemb force-pushed the fix-cppTango444 branch from 460afa1 to a302d7a Compare May 4, 2018 08:46
@bourtemb bourtemb merged commit e76586e into tango-controls:tango-9-lts May 4, 2018
bourtemb added a commit to bourtemb/cppTango that referenced this pull request Jul 17, 2018
…controls#444) (tango-controls#445)

This is to reduce the impact of a bug present in ZMQ 4.2.0 and ZMQ 4.2.1
which led to a bad lwm and hwm calculation when ZMQ_RCVHWM was set after
the bind of the socket. See cppTango#444 for more details
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants