Documentation
¶
Index ¶
Constants ¶
View Source
const ( /* Stats update interval */ INTERVAL = 2 * time.Second )
Variables ¶
View Source
var Store = struct { sync.RWMutex handlers map[string]*Handler }{/* contains filtered or unexported fields */}
*
- Handlers Store
Functions ¶
Types ¶
type Handler ¶
type Handler struct { /* Server's name */ Name string /* Backends counters */ BackendsCounter *counters.BackendsBandwidthCounter /* Server traffic data */ Traffic chan core.ReadWriteCount /* Server current connections count */ Connections chan uint /* Current backends pool */ Backends chan []core.Backend /* Input channel for latest stats */ ServerStats chan counters.BandwidthStats // contains filtered or unexported fields }
*
- Handler processess data from server
type Stats ¶
type Stats struct { /* Current active client connections */ ActiveConnections uint `json:"active_connections"` /* Total received bytes from backend */ RxTotal uint64 `json:"rx_total"` /* Total transmitter bytes to backend */ TxTotal uint64 `json:"tx_total"` /* Received bytes to backend / second */ RxSecond uint `json:"rx_second"` /* Transmitted bytes to backend / second */ TxSecond uint `json:"tx_second"` /* Current backends pool */ Backends []core.Backend `json:"backends"` }
*
- Stats of the Server
Click to show internal directories.
Click to hide internal directories.