Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Importer ¶
type Importer struct {
// contains filtered or unexported fields
}
Importer loads SQL files produced by go-dump into a MySQL server.
func (*Importer) ImportDirectory ¶
ImportDirectory loads all SQL files in dir matching pattern. Schema (definition) files are loaded serially first; data files run in parallel. Pass a non-nil LoadState to enable resume (skip already-loaded files).
type LoadState ¶
type LoadState struct {
StartTime time.Time `json:"start_time"`
CompletedFiles []string `json:"completed_files"`
// contains filtered or unexported fields
}
LoadState persists which files have been successfully loaded, enabling --resume. Written atomically to <directory>/load-state.json after each successful file load.
func NewLoadState ¶
NewLoadState reads an existing load-state.json from dir, or returns a fresh state.
Click to show internal directories.
Click to hide internal directories.