In part 1 we saw how to create a simple server using Reply and Request pattern. We mentioned in passing other kinds of sockets we can make using ZeroMQ. We will cover a simple example of a Push and Pull pattern using zmq.PULL and ZMQ.PUSH and also cover one for Publish and Subscribe with ZMQ.PUB and ZMQ.SUB. The content will be very similar to the one from the previous tutorial and we will just tweak a few values to have the example up and running.
The basic idea with Publish coupled with Subscribe and Push with Pull is all about the flow of information, where we have one or more nodes Producing/Pushing out information for example a temperature sensor sending out data, a smart-wear gadget sending health data say like hearbeats from a smart watch, a drone or a even the self-driving car you might be designing(who knows you might be the next Elon Musk). On the other end we have a node Subscribing/Pulling information from a source for example a data center, heating system reacting to the temperature change and t