Versions in this module Expand all Collapse all v0 v0.5.4 Sep 24, 2020 Changes in this version + const CheckStaledAutopeerInterval + const SendQueueSize + func Caller(handler interface{}, params ...interface{}) + func IdentityCaller(handler interface{}, params ...interface{}) + func NewID(ip string, port uint16) string + func OriginAddressCaller(handler interface{}, params ...interface{}) + type ConnectionOrigin byte + const Inbound + const Outbound + type Events struct + HeartbeatUpdated *events.Event + type Info struct + Address string + Alias string + Autopeered bool + AutopeeringID string + Connected bool + ConnectionType string + Domain string + DomainWithPort string + NumberOfAllTransactions uint32 + NumberOfDroppedSentPackets uint32 + NumberOfKnownTransactions uint32 + NumberOfNewTransactions uint32 + NumberOfReceivedHeartbeats uint32 + NumberOfReceivedMilestoneReq uint32 + NumberOfReceivedTransactionReq uint32 + NumberOfSentHeartbeats uint32 + NumberOfSentMilestoneReq uint32 + NumberOfSentPackets uint32 + NumberOfSentTransactions uint32 + NumberOfSentTransactionsReq uint32 + NumberOfStaleTransactions uint32 + Peer *Peer + Port uint16 + PreferIPv6 bool + type Metrics struct + DroppedPackets atomic.Uint32 + KnownTransactions atomic.Uint32 + NewTransactions atomic.Uint32 + ReceivedHeartbeats atomic.Uint32 + ReceivedMilestoneRequests atomic.Uint32 + ReceivedTransactionRequests atomic.Uint32 + ReceivedTransactions atomic.Uint32 + SentHeartbeats atomic.Uint32 + SentMilestoneRequests atomic.Uint32 + SentPackets atomic.Uint32 + SentTransactionRequests atomic.Uint32 + SentTransactions atomic.Uint32 + StaleTransactions atomic.Uint32 + type Peer struct + Addresses *iputils.IPAddresses + Autopeering *peer.Peer + Conn *network.ManagedConnection + ConnectionOrigin ConnectionOrigin + Disconnected bool + Duplicate bool + Events Events + ID string + InitAddress *iputils.OriginAddress + LatestHeartbeat *sting.Heartbeat + Metrics Metrics + MoveBackToReconnectPool bool + PrimaryAddress net.IP + Protocol *protocol.Protocol + SendQueue chan []byte + func NewInboundPeer(remoteAddr net.Addr) *Peer + func NewOutboundPeer(originAddr *iputils.OriginAddress, primaryAddr net.IP, port uint16, ...) *Peer + func (p *Peer) CheckStaledAutopeer(maxPercentage int) (bool, float32) + func (p *Peer) CouldHaveDataFor(index milestone.Index) bool + func (p *Peer) EnqueueForSending(data []byte) + func (p *Peer) Handshaked() bool + func (p *Peer) HasDataFor(index milestone.Index) bool + func (p *Peer) Info() *Info + func (p *Peer) IsInbound() bool