metric

package
v0.16.1 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Metric

type Metric struct {
	InSrcCnt                      int
	InDstCnt                      int
	InSrcAndDstByKeyCnt           int
	InSrcAndDstByIdButNotByKeyCnt int
	JustInSrcByKeyAndIdCnt        int
	JustInDstByKeyAndIdCnt        int

	ToInsertCnt int
	ToUpdateCnt int
	ToUpsertCnt int
	ToDeleteCnt int

	Strategy        uint8
	IndexTime       time.Duration
	CategorizeTime  time.Duration
	FetchTime       time.Duration
	CompareDataTime time.Duration
	TotalTime       time.Duration

	Insert Summary
	Upsert Summary
	Update Summary
	Delete Summary
	Total  Total
	Err    error

	Table string
}

func (*Metric) DelRowsAffected

func (m *Metric) DelRowsAffected() int

DelRowsAffected returns the number of rows affected by an delete.

func (*Metric) DeletingTime

func (m *Metric) DeletingTime() time.Duration

DeletingTime returns deleting duration.

func (*Metric) InsRowsAffected

func (m *Metric) InsRowsAffected() int

InsRowsAffected returns the number of rows affected by an insert.

func (*Metric) InsertingTime

func (m *Metric) InsertingTime() time.Duration

InsertingTime returns inserting duration.

func (*Metric) MergedTable added in v0.15.0

func (m *Metric) MergedTable() string

func (*Metric) MergingTime

func (m *Metric) MergingTime() time.Duration

MergingTime returns total merging duration.

func (*Metric) Report

func (m *Metric) Report() string

Report returns []string with merge report.

func (*Metric) RowsAffected

func (m *Metric) RowsAffected() int

RowsAffected returns the number of rows affected by an insert, upsert, update or delete.

func (*Metric) Summary

func (m *Metric) Summary()

func (*Metric) UpdRowsAffected

func (m *Metric) UpdRowsAffected() int

UpdRowsAffected returns the number of rows affected by an update.

func (*Metric) UpdatingTime

func (m *Metric) UpdatingTime() time.Duration

UpdatingTime returns updating duration.

func (*Metric) UpsRowsAffected

func (m *Metric) UpsRowsAffected() int

UpsRowsAffected returns the number of rows affected by an upsert.

func (*Metric) UpsertingTime

func (m *Metric) UpsertingTime() time.Duration

UpsertingTime returns upserting duration.

type Operation

type Operation struct {
	Affected int
	Time     time.Duration
}

type Summary

type Summary struct {
	Transient Operation
	Main      Operation
	Total     Operation
}

type Total

type Total struct {
	TransientAffected int
	MainAffected      int
	TransientTime     time.Duration
	MainTime          time.Duration
	TotalAffected     int
	TotalTime         time.Duration
	Report            []string
}

Jump to

Keyboard shortcuts

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