slowlog

package
v1.18.0 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2022 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FilenameFunc

type FilenameFunc func() (string, error)

type Iter

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

func NewIter

func NewIter(logger *pct.Logger, filename FilenameFunc, tickChan chan time.Time) *Iter

func (*Iter) IntervalChan

func (i *Iter) IntervalChan() chan *iter.Interval

func (*Iter) Start

func (i *Iter) Start()

func (*Iter) Stop

func (i *Iter) Stop()

func (*Iter) TickChan

func (i *Iter) TickChan() chan time.Time

type Job

type Job struct {
	Id             string
	SlowLogFile    string
	RunTime        time.Duration
	StartOffset    int64
	EndOffset      int64
	ExampleQueries bool
	RetainSlowLogs int
}

func (*Job) String

func (j *Job) String() string

type RealWorkerFactory

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

func NewRealWorkerFactory

func NewRealWorkerFactory(logChan chan proto.LogEntry) *RealWorkerFactory

func (*RealWorkerFactory) Make

func (f *RealWorkerFactory) Make(name string, config pc.QAN, mysqlConn mysql.Connector) *Worker

type Worker

type Worker struct {

	// --
	ZeroRunTime bool // testing
	// contains filtered or unexported fields
}

func NewWorker

func NewWorker(logger *pct.Logger, config pc.QAN, mysqlConn mysql.Connector) *Worker

func (*Worker) Cleanup

func (w *Worker) Cleanup() error

func (*Worker) MakeLogParser

func (w *Worker) MakeLogParser(file *os.File, opts log.Options) log.LogParser

func (*Worker) Run

func (w *Worker) Run() (*report.Result, error)

func (*Worker) SetConfig

func (w *Worker) SetConfig(config pc.QAN)

func (*Worker) SetLogParser

func (w *Worker) SetLogParser(p log.LogParser)

func (*Worker) Setup

func (w *Worker) Setup(interval *iter.Interval) error

func (*Worker) Status

func (w *Worker) Status() map[string]string

func (*Worker) Stop

func (w *Worker) Stop() error

type WorkerFactory

type WorkerFactory interface {
	Make(name string, config pc.QAN, mysqlConn mysql.Connector) *Worker
}

Jump to

Keyboard shortcuts

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