def _init_gatherers(self, threads): logger.info('launching gatherers...') self.gatherer_s = self.context.socket(zmq.PUSH) self.gatherer_sink_s = self.context.socket(zmq.PULL) self.gatherer_s.bind(GATHERER_ADDR) self.gatherer_sink_s.bind(GATHERER_SINK_ADDR) for n in range(int(threads)): p = mp.Process(target=Gatherer().start) p.start() self.gatherers.append(p)
def _init_gatherers(self, threads): self.logger.info('launching gatherers...') for n in range(int(threads)): p = mp.Process(target=Gatherer().start) p.start()
def _init_gatherers(self, threads): self.logger.info('launching gatherers...') for n in range(int(threads)): t = threading.Thread(target=Gatherer(self.context).start) t.daemon = True t.start()