mirror of
https://github.com/waku-org/test-discv5.git
synced 2025-02-05 01:23:43 +00:00
chore: change order of output
This commit is contained in:
parent
1f2ac5154a
commit
9ed80d326d
16
main.go
16
main.go
@ -65,13 +65,6 @@ func main() {
|
|||||||
bootnodes = append(bootnodes, tree.Nodes()...)
|
bootnodes = append(bootnodes, tree.Nodes()...)
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(bootnodes) > 0 {
|
|
||||||
fmt.Println("Bootnodes:")
|
|
||||||
for i, b := range bootnodes {
|
|
||||||
fmt.Println(i+1, "-", b.String())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
config := discover.Config{
|
config := discover.Config{
|
||||||
PrivateKey: priv,
|
PrivateKey: priv,
|
||||||
Bootnodes: bootnodes,
|
Bootnodes: bootnodes,
|
||||||
@ -100,13 +93,20 @@ func main() {
|
|||||||
|
|
||||||
localnode.SetFallbackUDP(udpAddr.Port)
|
localnode.SetFallbackUDP(udpAddr.Port)
|
||||||
|
|
||||||
fmt.Println("\nYour node:")
|
fmt.Println("Your node:")
|
||||||
fmt.Println(localnode.Node())
|
fmt.Println(localnode.Node())
|
||||||
listener, err := discover.ListenV5(conn, localnode, config)
|
listener, err := discover.ListenV5(conn, localnode, config)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(bootnodes) > 0 {
|
||||||
|
fmt.Println("\nBootnodes:")
|
||||||
|
for i, b := range bootnodes {
|
||||||
|
fmt.Println(i+1, "-", b.String())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
peerDelay := 50 * time.Millisecond
|
peerDelay := 50 * time.Millisecond
|
||||||
bucketSize := 15
|
bucketSize := 15
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user