Documentation
¶
Overview ¶
Package pgxmgr loads and executes the migration scripts on a connection aquired from a pgx pool. All migrations are run incrementaly in seperate transaction blocks. Execution is terminated when ay migration fails and a rollback is performed to the beginning of this failing migration. Any previous migrations will already be committed.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Run ¶
Run loads and executes the migrations. The first argument needs to be an instance of a configured pgx connection pool. The second argument should be directory where the migration files are loaded from. Files with the signature of ##-##-####-<name>.sql will be loaded and executed in order. The three number groups stand for major, minor and fix version.
Types ¶
This section is empty.