Commit 1700208b authored by 赵威's avatar 赵威

consumer seek from latest

parent 17b9af1d
...@@ -17,6 +17,7 @@ def consume_kafka(device_dict, diary_dict, tractate_dict, diary_predict_fn, trac ...@@ -17,6 +17,7 @@ def consume_kafka(device_dict, diary_dict, tractate_dict, diary_predict_fn, trac
auto_commit_interval_ms=1000) auto_commit_interval_ms=1000)
consumer.subscribe(["gm-portrait-update-device"]) consumer.subscribe(["gm-portrait-update-device"])
consumer.seek(0, 2)
try: try:
for msg in consumer: for msg in consumer:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment