Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DBStats ¶
type DBStats struct {
MaxOpenConnections prometheus.Gauge // Maximum number of open connections to the database.
// Pool status
OpenConnections prometheus.Gauge // The number of established connections both in use and idle.
InUse prometheus.Gauge // The number of connections currently in use.
Idle prometheus.Gauge // The number of idle connections.
// Counters
WaitCount prometheus.Gauge // The total number of connections waited for.
WaitDuration prometheus.Gauge // The total time blocked waiting for a new connection.
MaxIdleClosed prometheus.Gauge // The total number of connections closed due to SetMaxIdleConns.
MaxLifetimeClosed prometheus.Gauge // The total number of connections closed due to SetConnMaxLifetime.
}
func (*DBStats) Collectors ¶
func (stats *DBStats) Collectors() (collector []prometheus.Collector)
get collector in stats
Click to show internal directories.
Click to hide internal directories.