github.com/ethereumproject/go-ethereum@v5.5.2+incompatible/p2p/mlog.go (about) 1 package p2p 2 3 import "github.com/ethereumproject/go-ethereum/logger" 4 5 var mlogServer = logger.MLogRegisterAvailable("server", mLogLinesServer) 6 7 var mLogLinesServer = []*logger.MLogT{ 8 mlogServerPeerAdded, 9 mlogServerPeerRemove, 10 } 11 12 var mlogServerPeerAdded = &logger.MLogT{ 13 Description: "Called once when a peer is added.", 14 Receiver: "SERVER", 15 Verb: "ADD", 16 Subject: "PEER", 17 Details: []logger.MLogDetailT{ 18 {Owner: "SERVER", Key: "PEER_COUNT", Value: "INT"}, 19 {Owner: "PEER", Key: "ID", Value: "STRING"}, 20 {Owner: "PEER", Key: "REMOTE_ADDR", Value: "STRING"}, 21 {Owner: "PEER", Key: "REMOTE_VERSION", Value: "STRING"}, 22 }, 23 } 24 25 var mlogServerPeerRemove = &logger.MLogT{ 26 Description: "Called once when a peer is removed.", 27 Receiver: "SERVER", 28 Verb: "REMOVE", 29 Subject: "PEER", 30 Details: []logger.MLogDetailT{ 31 {Owner: "SERVER", Key: "PEER_COUNT", Value: "INT"}, 32 {Owner: "PEER", Key: "ID", Value: "STRING"}, 33 {Owner: "REMOVE", Key: "REASON", Value: "QUOTEDSTRING"}, 34 }, 35 }