Skip to content

Commit f05582c

Browse files
committed
refactor: Clean up the PeerHolder access/iteration/remove
This patch expands the PeerHolder API allowing for encapsulation of the peer state from the code that needs to iterate over initialized peers. This cleans up peer iteration/removal allowing for a much simpler design. 1) Introduce new APIs for PeerHolder: * initialized_peers_mut() * initialized_peer_node_ids() * remove_peer_by_descriptor() 2) Clean up event handler iteration using new APIs 3) Unify the timer_tick and DisconnectPeer event disconnect path using new APIs 4) Convert get_peer_node_ids() to use new API
1 parent aa94583 commit f05582c

File tree

1 file changed

+97
-106
lines changed

1 file changed

+97
-106
lines changed

0 commit comments

Comments
 (0)