diff

package
v0.0.0-...-145e2ed Latest Latest
Warning

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

Go to latest
Published: Dec 25, 2025 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetSnapshot

func GetSnapshot(latestSnap []string, snap string, db *sql.DB) string

GetSnapshot get the snapshot

Types

type ChunkDML

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

ChunkDML SQL struct for each chunk

type Diff

type Diff struct {
	FixSQLDir     string
	CheckpointDir string
	// contains filtered or unexported fields
}

Diff contains two sql DB, used for comparing.

func NewDiff

func NewDiff(ctx context.Context, cfg *config.Config) (diff *Diff, err error)

NewDiff returns a Diff instance.

func (*Diff) BinGenerate

func (df *Diff) BinGenerate(ctx context.Context, targetSource source.Source, tableRange *splitter.RangeInfo, count int64) (*splitter.RangeInfo, error)

BinGenerate ...

func (*Diff) Close

func (df *Diff) Close()

Close the current struct

func (*Diff) Equal

func (df *Diff) Equal(ctx context.Context) error

Equal tests whether two database have same data and schema.

func (*Diff) PrintSummary

func (df *Diff) PrintSummary(ctx context.Context) bool

PrintSummary print the summary and return true if report is passed

func (*Diff) StructEqual

func (df *Diff) StructEqual(ctx context.Context) error

StructEqual compare tables from downstream

Jump to

Keyboard shortcuts

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