outboundstats

package
v1.2.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 6, 2026 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OutStats

type OutStats struct {
	sync.Mutex
	Map map[string]*OutboundHandlerStats
	// contains filtered or unexported fields
}

func NewOutStats

func NewOutStats() *OutStats

func (*OutStats) Close

func (o *OutStats) Close() error

func (*OutStats) Get

func (o *OutStats) Get(tag string) *OutboundHandlerStats

func (*OutStats) IsHandlerActive

func (o *OutStats) IsHandlerActive(tag string) bool

func (*OutStats) Start

func (o *OutStats) Start() error

type OutboundHandlerStats

type OutboundHandlerStats struct {
	UpCounter   atomic.Uint64
	DownCounter atomic.Uint64
	// The time when the up/down counter is reset
	Interval   atomic.Value
	Throughput atomic.Uint64
	Ping       atomic.Uint64
	// The time when this handler is selected to handle
	Time atomic.Value
	// The time when there is response traffic from this handler
	ActiveTime atomic.Value //time.Time
}

func NewHandlerStats

func NewHandlerStats(throughput uint64, ping uint64) *OutboundHandlerStats

func (*OutboundHandlerStats) AddPing

func (s *OutboundHandlerStats) AddPing(v uint64)

func (*OutboundHandlerStats) AddThroughput

func (s *OutboundHandlerStats) AddThroughput(v uint64)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL