mysql

package
v0.0.0-...-e06cd52 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateModule

func CreateModule(config *Config) monitoring.Module

Types

type Config

type Config struct {
	Enabled        bool    `toml:"enabled" comment:"Set 'false' to disable checking available updates"`
	Connect        string  `toml:"connect" comment:"Use 127.0.0.1 or the path to the mysql.socket, connecting to remote databases is not supported"`
	User           string  `` /* 131-byte string literal not displayed */
	Password       string  `toml:"password" comment:"Maximum time the package manager is allowed to spend fetching available updates"`
	ConnectTimeout float64 `toml:"connect_timeout" comment:"Maximum time to wait for mysql server to connect using provided credentials"`
}

func (*Config) Validate

func (cfg *Config) Validate() error

type Mysql

type Mysql struct {
	// contains filtered or unexported fields
}

func (*Mysql) GetDescription

func (r *Mysql) GetDescription() string

func (*Mysql) IsEnabled

func (r *Mysql) IsEnabled() bool

func (*Mysql) Run

func (r *Mysql) Run() ([]*monitoring.ModuleReport, error)

type Status

type Status struct {
	Selects        int64
	Updates        int64
	Inserts        int64
	Deletes        int64
	Replaces       int64
	CallProcedures int64
	CacheHits      int64
	Commits        int64

	InnoDBReadBytes  int64
	InnoDBWriteBytes int64
	ReadBytes        int64
	WriteBytes       int64
}

func (*Status) Queries

func (s *Status) Queries() int64

Jump to

Keyboard shortcuts

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