migrator

package
v0.0.0-...-b3895e6 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Migrator

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

Migrator manages the migration of Ace as new versioned tsvs come in.

func New

func New(aceBack backend.Backend,
	metaBack metadata.Reader,
	blueprintClient blueprint.Client,
	versions versions.GetterSetter,
	pollPeriod time.Duration,
	waitProcessorPeriod time.Duration,
	offpeakStartHour int,
	offpeakDurationHours int,
	versionIncrement chan VersionIncrement,
	onpeakMigrationTimeoutMs int,
	offpeakMigrationTimeoutMs int) *Migrator

New returns a new Migrator for migrating schemas

func (*Migrator) Close

func (m *Migrator) Close()

Close signals the migrator to stop looking for new migrations and waits until it's finished any migrations.

type VersionIncrement

type VersionIncrement struct {
	Table    string
	Version  int
	Response chan error
}

VersionIncrement is used to send a request to increment a table's version w/o running a migration.

Jump to

Keyboard shortcuts

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