migrations

package
v3.0.2 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2025 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Migration

type Migration interface {
	NeedsMigration(ctx context.Context) (bool, error)
	Migrate(ctx context.Context) error
	Name() string
}

type MigrationRunner

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

func NewMigrationRunner

func NewMigrationRunner(cfg config.Config, storage models.Storage, leaseManager locker.EtcdLeaseManager) MigrationRunner

func (MigrationRunner) Run

func (m MigrationRunner) Run(ctx context.Context) error

type V0toV1

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

func NewV0toV1Migration

func NewV0toV1Migration(hostname string, leaseManager locker.EtcdLeaseManager, storage models.Storage) V0toV1

func (V0toV1) Migrate

func (m V0toV1) Migrate(ctx context.Context) error

func (V0toV1) Name

func (m V0toV1) Name() string

func (V0toV1) NeedsMigration

func (m V0toV1) NeedsMigration(ctx context.Context) (bool, error)

type V2toV3

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

func NewV2toV3Migration

func NewV2toV3Migration(hostname string, storage models.Storage) V2toV3

func (V2toV3) Migrate

func (m V2toV3) Migrate(ctx context.Context) error

func (V2toV3) Name

func (m V2toV3) Name() string

func (V2toV3) NeedsMigration

func (m V2toV3) NeedsMigration(ctx context.Context) (bool, error)

Jump to

Keyboard shortcuts

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