dbump_sqlite

package module
v0.0.0-...-cf8f52e Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Schema for the dbump version table. Default is empty which means "public" schema.
	Schema string
	// Table for the dbump version table. Default is empty which means "_dbump_log" table.
	Table string
	// contains filtered or unexported fields
}

Config for the migrator.

type Migrator

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

Migrator to migrate Postgres.

func NewMigrator

func NewMigrator(conn *sql.DB, cfg Config) *Migrator

NewMigrator instantiates new Migrator.

func (*Migrator) DoStep

func (s *Migrator) DoStep(ctx context.Context, step dbump.Step) error

DoStep is a method from dbump.Migrator interface.

func (*Migrator) Drop

func (s *Migrator) Drop(ctx context.Context) error

Drop is a method from dbump.Migrator interface.

func (*Migrator) Init

func (s *Migrator) Init(ctx context.Context) error

Init is a method from dbump.Migrator interface.

func (*Migrator) LockDB

func (s *Migrator) LockDB(ctx context.Context) error

LockDB is a method from dbump.Migrator interface.

func (*Migrator) UnlockDB

func (s *Migrator) UnlockDB(ctx context.Context) error

UnlockDB is a method from dbump.Migrator interface.

func (*Migrator) Version

func (s *Migrator) Version(ctx context.Context) (version int, err error)

Version is a method from dbump.Migrator interface.

Jump to

Keyboard shortcuts

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