Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MinerProtocol ¶ added in v0.12.0
type MinerProtocol struct {
// ObservedAt is the time the observation was made.
ObservedAt time.Time `pg:",pk,notnull"`
// MinerID is the address of the miner observed.
MinerID string `pg:",pk,notnull"`
// PeerID is the peerID of the miner observed.
PeerID string
// Agent is the raw peer agent string of the miner.
Agent string
// Protocols is the list of protocols supported by the miner.
Protocols []string
// contains filtered or unexported fields
}
func (*MinerProtocol) Persist ¶ added in v0.12.0
func (m *MinerProtocol) Persist(ctx context.Context, s model.StorageBatch, _ model.Version) error
type MinerProtocolList ¶ added in v0.12.0
type MinerProtocolList []*MinerProtocol
func (MinerProtocolList) Persist ¶ added in v0.12.0
func (m MinerProtocolList) Persist(ctx context.Context, s model.StorageBatch, _ model.Version) error
type PeerAgent ¶
type PeerAgent struct {
// SurveyerPeerID is the peer ID of the node performing the survey
SurveyerPeerID string `pg:",pk,notnull"`
// ObservedAt is the time the observation was made
ObservedAt time.Time `pg:",pk,notnull"`
// RawAgent is the raw peer agent string
RawAgent string `pg:",pk,notnull"`
// NormalizedAgent is a parsed version of peer agent string, stripping out patch versions
NormalizedAgent string `pg:",notnull"`
// Count is the number of peers with the associated agent
Count int64 `pg:",use_zero,notnull"`
// contains filtered or unexported fields
}
type PeerAgentList ¶
type PeerAgentList []*PeerAgent
func (PeerAgentList) Persist ¶
func (l PeerAgentList) Persist(ctx context.Context, s model.StorageBatch, _ model.Version) error
Click to show internal directories.
Click to hide internal directories.