ZeroMQ PUB socket buffers all my out going data when it is connecting

前端 未结 6 1756
栀梦
栀梦 2021-02-02 00:00

I noticed that a zeromq PUB socket will buffers all outgoing data if it is connecting, for example

import zmq
import time
context = zmq.Context()

# create a PUB         


        
6条回答
  •  爱一瞬间的悲伤
    2021-02-02 00:46

    So bind() and connect() result in two different behaviors. Why don't you just choose which one you prefer (it seems like bind()) and use that?

    It is indeed a feature of ZeroMQ in general that it buffers outgoing messages until a connection is made.

提交回复
热议问题