etl

package
v0.0.0-...-0764311 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Version = 0.1
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine

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

Engine extracts and loads data from database with specific dialect.

func NewEngine

func NewEngine(ctx context.Context, cfg config.Config, dsn string, logger *zap.Logger) (*Engine, error)

NewEngine returns a new Engine instance.

func (*Engine) Describe

func (e *Engine) Describe(ctx context.Context, tableName string) (dialectpkg.Table, error)

Describe returns a table from its name.

func (*Engine) Extract

func (e *Engine) Extract(ctx context.Context, outputPath, query string) error

Extract extracts data to an output directory with a table name and its query.

func (*Engine) Load

func (e *Engine) Load(ctx context.Context, outputPath string) error

Load loads data from an output directory.

func (*Engine) Shutdown

func (e *Engine) Shutdown(ctx context.Context) error

Shutdown shutdowns the Engine.

Jump to

Keyboard shortcuts

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