p2p: measure subprotocol bandwidth usage
This commit is contained in:
@ -39,9 +39,13 @@ import (
|
||||
// separate Msg with a bytes.Reader as Payload for each send.
|
||||
type Msg struct {
|
||||
Code uint64
|
||||
Size uint32 // size of the paylod
|
||||
Size uint32 // Size of the raw payload
|
||||
Payload io.Reader
|
||||
ReceivedAt time.Time
|
||||
|
||||
meterCap Cap // Protocol name and version for egress metering
|
||||
meterCode uint64 // Message within protocol for egress metering
|
||||
meterSize uint32 // Compressed message size for ingress metering
|
||||
}
|
||||
|
||||
// Decode parses the RLP content of a message into
|
||||
|
Reference in New Issue
Block a user