Description
In some of my code, my server use the zmq 4.1.6 with PUB mode, and another old server with SUB mode build with zmq 2.2.0.
Then I cannot receive anything in the sub server.
Here is the example:
https://gist.github.com/laplaceyang/8cf1c004832f4ef618c69ceb868ef33b
build the PUB server with zmq 4.1.6 and SUB server with zmq 2.x
but if i build the server with zmq 3.x, it works.
It seems that change in stream_engine.cpp lead to this problem
In zmq 3.x, we have function
we inject a phantom subscription message and process identity msg in the same function
but in zmq 4.x, we separate it to two function
identity process func
inject phantom subscription message function
This change lead that,we should trigger two socket in event to finish subscribe.
but I dump the tcp package,
The SUB server just send one package to PUB.