争霸测试

This commit is contained in:
wuaho 2021-07-06 10:54:30 +08:00
parent d4a0e5dcfc
commit 49f45afaaa
2 changed files with 2 additions and 2 deletions

View File

@ -17,7 +17,7 @@ def create_consumer(partition=-1):
# print(msg)
topic = msg.topic
val = msg.value
if val.get('owner_name') not in ('gmhdgdt', 'gmhdtt'):
if val.get('properties',{}).get('owner_name') not in ('gmhdgdt', 'gmhdtt'):
continue
yield topic, val

View File

@ -11,7 +11,7 @@ class EventAttr:
attr = self.event_attr.get(key)
if not attr:
self.event_attr[key] = self.rdb.smembers(key) or set()
return self.event_attr[key]
return set(self.event_attr[key])
def set_event_attr(self, key, *data):
self.rdb.sadd(key, *data)