Documentation
¶
Index ¶
- type Store
- func (s *Store) AppliedVersions(ctx context.Context) (map[int64]bool, error)
- func (s *Store) Close() error
- func (s *Store) MarkApplied(ctx context.Context, tx *sqlx.Tx, version int64, name string) error
- func (s *Store) MarkRolledBack(ctx context.Context, tx *sqlx.Tx, version int64) error
- func (s *Store) WithExclusive(ctx context.Context, fn func(*sqlx.Tx) error) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func NewWithMock ¶
NewWithMock is only for tests; allows injection of custom DB.
func (*Store) AppliedVersions ¶
Return map[version]isApplied.
func (*Store) MarkApplied ¶
Add migration record.
func (*Store) MarkRolledBack ¶
Remove migration record.
Click to show internal directories.
Click to hide internal directories.