Documentation
¶
Overview ¶
Package dbcompare compares the schemas and complete rows of two DALgo databases. It keeps provider values lossless and delegates keyed row matching and field-delta classification to DALgo recordops.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DifferenceCounts ¶
type RecordDiff ¶
type RelationReport ¶
type RelationReport struct {
Name string `json:"name"`
RightName string `json:"rightName,omitempty"`
Kind string `json:"kind"`
Identity string `json:"identity"`
LeftRows int64 `json:"leftRows"`
RightRows int64 `json:"rightRows"`
Counts DifferenceCounts `json:"counts"`
Details []RecordDiff `json:"details,omitempty"`
DetailsLimited bool `json:"detailsLimited,omitempty"`
}
type Report ¶
type Report struct {
LeftName string `json:"leftName"`
RightName string `json:"rightName"`
SchemaChanges []string `json:"schemaChanges"`
Warnings []string `json:"warnings,omitempty"`
Relations []RelationReport `json:"relations"`
Summary DifferenceCounts `json:"summary"`
DetailsLimited bool `json:"detailsLimited"`
}
func Compare ¶
func Compare(ctx context.Context, leftName string, left dal.DB, rightName string, right dal.DB, options Options) (Report, error)
Compare compares the union of both relation inventories and reads every row from every common collection. DetailLimit affects only retained examples; it never stops reading either source.
Click to show internal directories.
Click to hide internal directories.