mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
p2p/discover: add live flag in debug node
This commit is contained in:
parent
1d896e8165
commit
dc3f78bb81
2 changed files with 2 additions and 0 deletions
|
|
@ -33,6 +33,7 @@ type BucketNode struct {
|
||||||
Node *enode.Node `json:"node"`
|
Node *enode.Node `json:"node"`
|
||||||
AddedAt time.Time `json:"added"`
|
AddedAt time.Time `json:"added"`
|
||||||
Checks int `json:"checks"`
|
Checks int `json:"checks"`
|
||||||
|
Live bool `json:"live"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// node represents a host on the network.
|
// node represents a host on the network.
|
||||||
|
|
|
||||||
|
|
@ -167,6 +167,7 @@ func (tab *Table) Nodes() [][]BucketNode {
|
||||||
nodes[i][j] = BucketNode{
|
nodes[i][j] = BucketNode{
|
||||||
Node: n.Node,
|
Node: n.Node,
|
||||||
Checks: int(n.livenessChecks),
|
Checks: int(n.livenessChecks),
|
||||||
|
Live: n.isValidatedLive,
|
||||||
AddedAt: n.addedAt,
|
AddedAt: n.addedAt,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue