mirror of
https://github.com/status-im/nim-libp2p.git
synced 2025-02-27 20:10:50 +00:00
docs: change advertisements to registration
This commit is contained in:
parent
a6c5343998
commit
db2699b3f1
@ -506,11 +506,11 @@ proc advertisePeer(rdv: RendezVous, peer: PeerId, msg: seq[byte]) {.async.} =
|
|||||||
discard await advertiseWrap().withTimeout(5.seconds)
|
discard await advertiseWrap().withTimeout(5.seconds)
|
||||||
|
|
||||||
proc advertise*(
|
proc advertise*(
|
||||||
rdv: RendezVous, ns: string, ttl: Duration, peers: seq[PeerId]
|
rdv: RendezVous, ns: string, ttl: Duration = rdv.minDuration, peers: seq[PeerId]
|
||||||
) {.async.} =
|
) {.async.} =
|
||||||
## The advertise async procedure sends advertisements for a namespace
|
## The advertise async procedure sends a registration for a namespace
|
||||||
## to a sequence of peers. It encodes and sends a signed peer record
|
## to a sequence of peers. It encodes and sends a signed peer record
|
||||||
## along with a time-to-live value. Advertisements are sent
|
## along with a time-to-live value. The registrations are sent
|
||||||
## concurrently to all specified peers.
|
## concurrently to all specified peers.
|
||||||
##
|
##
|
||||||
if ns.len notin 1 .. 255:
|
if ns.len notin 1 .. 255:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user