Skip to content

Commit 6a7203b

Browse files
committed
Add note about ping keepalive
1 parent d4edece commit 6a7203b

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

receptor/entrypoints.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111

1212
def run_as_node(config):
1313
async def node_keepalive():
14+
# NOTE: I'm not really happy with this, I'd love to be able to await Peer(node).ping()
15+
# and then verify the status under a timeout rather than just throw away the result and
16+
# rely on the connection logic
1417
for node_id in controller.receptor.router.get_nodes():
1518
await controller.ping(node_id, expected_response=False)
1619
absolute_call_time = (((int(controller.loop.time()) + 1) // config.node_keepalive_interval) + 1) * config.node_keepalive_interval

0 commit comments

Comments
 (0)