mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
fixup! cluster/websocket: Automatic WebSocket client topic subscription
This commit is contained in:
parent
8edec9885a
commit
cf0669ade3
4 changed files with 4 additions and 6 deletions
|
@ -1,5 +1,5 @@
|
||||||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||||
connected
|
connected
|
||||||
got ack
|
got ack
|
||||||
ack[endpoint] in topic_parts True
|
ack[endpoint] in topic True
|
||||||
event [{'@data-type': 'string', 'data': 'pong'}, {'@data-type': 'vector', 'data': [{'@data-type': 'count', 'data': 42}]}]
|
event [{'@data-type': 'string', 'data': 'pong'}, {'@data-type': 'vector', 'data': [{'@data-type': 'count', 'data': 42}]}]
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||||
connected
|
connected
|
||||||
got ack
|
got ack
|
||||||
ack[endpoint] in topic_parts True
|
ack[endpoint] in topic True
|
||||||
event [{'@data-type': 'string', 'data': 'pong'}, {'@data-type': 'vector', 'data': [{'@data-type': 'count', 'data': 42}]}]
|
event [{'@data-type': 'string', 'data': 'pong'}, {'@data-type': 'vector', 'data': [{'@data-type': 'count', 'data': 42}]}]
|
||||||
|
|
|
@ -78,8 +78,7 @@ def run(ws_url):
|
||||||
tc.send_json(wstest.build_event_v1("/test/pings/", "ping", [42]))
|
tc.send_json(wstest.build_event_v1("/test/pings/", "ping", [42]))
|
||||||
pong = tc.recv_json(timeout=3)
|
pong = tc.recv_json(timeout=3)
|
||||||
topic, event = pong["topic"], pong["data"][2]["data"][0:2]
|
topic, event = pong["topic"], pong["data"][2]["data"][0:2]
|
||||||
topic_parts = topic.split("/")
|
print("ack[endpoint] in topic", ack["endpoint"] in topic)
|
||||||
print("ack[endpoint] in topic_parts", ack["endpoint"] in topic_parts)
|
|
||||||
print("event", event)
|
print("event", event)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -76,8 +76,7 @@ def run(ws_url):
|
||||||
tc.send_json(wstest.build_event_v1("/test/pings/", "ping", [42]))
|
tc.send_json(wstest.build_event_v1("/test/pings/", "ping", [42]))
|
||||||
pong = tc.recv_json(timeout=3)
|
pong = tc.recv_json(timeout=3)
|
||||||
topic, event = pong["topic"], pong["data"][2]["data"][0:2]
|
topic, event = pong["topic"], pong["data"][2]["data"][0:2]
|
||||||
topic_parts = topic.split(".")
|
print("ack[endpoint] in topic", ack["endpoint"] in topic)
|
||||||
print("ack[endpoint] in topic_parts", ack["endpoint"] in topic_parts)
|
|
||||||
print("event", event)
|
print("event", event)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue