mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-23 03:17:43 +08:00
add muxer type to json output
License: MIT Signed-off-by: Jeromy <why@ipfs.io>
This commit is contained in:
parent
4a029c7374
commit
795b3cc4c7
@ -88,6 +88,11 @@ var swarmPeersCmd = &cmds.Command{
|
||||
Peer: pid.Pretty(),
|
||||
}
|
||||
|
||||
swcon, ok := c.(*swarm.Conn)
|
||||
if ok {
|
||||
ci.Muxer = fmt.Sprintf("%T", swcon.StreamConn().Conn())
|
||||
}
|
||||
|
||||
if verbose || latency {
|
||||
ci.Latency = n.Peerstore.LatencyEWMA(pid).String()
|
||||
}
|
||||
@ -147,6 +152,7 @@ type connInfo struct {
|
||||
Addr string
|
||||
Peer string
|
||||
Latency string
|
||||
Muxer string
|
||||
Streams []streamInfo
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user