Updated networking flow (markdown)
parent
2de2524dce
commit
28b5e739e5
|
@ -26,8 +26,9 @@ beacon_chain/libp2p_backend.nim:
|
|||
vendor/nim-libp2p/libp2p/switch.nim:
|
||||
|
||||
- Switch.start()
|
||||
- for each Switch.transports and each Switch.peerInfo awaits Transport.listen(MultiAddress, inner `handle` closure)
|
||||
- returns a seq of these futures
|
||||
- for each Switch.transports and each Switch.peerInfo awaits Transport.listen(MultiAddress, Switch.start.handle)
|
||||
- (returns a seq of these futures)
|
||||
- awaits PubSub.start() on Switch.pubSub
|
||||
- Switch.start.handle(Connection)
|
||||
- awaits Switch.upgradeIncoming(Connection)
|
||||
- awaits Connection.close()
|
||||
|
@ -40,4 +41,4 @@ vendor/nim-libp2p/libp2p/switch.nim:
|
|||
- Switch.upgradeIncoming.securedHandler(Connection, proto: string)
|
||||
- awaits Secure.secure(Connection) and saves the result in `sconn` - this seems to be the same as `conn`
|
||||
- for each MuxerProvider value in Switch.muxers, calls Multistream.addHandler(MuxerProvider.codec, MuxerProvider)
|
||||
- awaits Multistream.handle(sconn: Connection)
|
||||
- awaits Multistream.handle(sconn: Connection)
|
||||
|
|
Loading…
Reference in New Issue