2017-04-12 16:20:00,506 DEBUG 403 Sending 1 messages to broker 76
2017-04-12 16:20:00,569 DEBUG 464 Successfully sent 1/1 messages to broker 76
2017-04-12 16:20:16,956 DEBUG 190 Finalising <pykafka.producer.Producer at 0x314c5f8L>
2017-04-12 16:20:16,956 INFO 489 Blocking until all messages are sent
2017-04-12 16:20:20,605 INFO 547 Worker exited for broker atomtree003:9092
2017-04-12 16:20:20,605 INFO 489 Blocking until all messages are sent
2017-04-12 16:20:20,605 INFO 184 RequestHandler.stop: about to flush requests queue
2017-04-12 16:20:20,605 INFO 184 RequestHandler.stop: about to flush requests queue
2017-04-12 16:20:20,605 INFO 184 RequestHandler.stop: about to flush requests queue 不知道楼主程序怎么写的。这个应该是正常退出。
上面是发送消息到 broker 76
发送成功
成功之后,worker退出
停止,然后接着刷新请求队列.
下面代码
[mw_shl_code=python,true]def stop(self):
"""Stop the request processor."""
shared = self.shared
self.shared = None
log.info("RequestHandler.stop: about to flush requests queue")
shared.requests.join()
shared.ending.set()[/mw_shl_code]
来自下面附件
python.rar
(1.96 KB, 下载次数: 0)
|