Skip to main content
Version: 4.5

Class: MigrationRunner#

migrations.MigrationRunner

Constructors#

constructor#

+ new MigrationRunner(driver: AbstractSqlDriver<AbstractSqlConnection>, options: MigrationsOptions, config: Configuration<IDatabaseDriver<Connection>>): MigrationRunner

Parameters:#

NameType
driverAbstractSqlDriver<AbstractSqlConnection>
optionsMigrationsOptions
configConfiguration<IDatabaseDriver<Connection>>

Returns: MigrationRunner

Defined in: packages/migrations/src/MigrationRunner.ts:9

Properties#

config#

Protected Readonly config: Configuration<IDatabaseDriver<Connection>>


connection#

Private Readonly connection: AbstractSqlConnection

Defined in: packages/migrations/src/MigrationRunner.ts:7


driver#

Protected Readonly driver: AbstractSqlDriver<AbstractSqlConnection>


helper#

Private Readonly helper: SchemaHelper

Defined in: packages/migrations/src/MigrationRunner.ts:8


masterTransaction#

Private Optional masterTransaction: any

Defined in: packages/migrations/src/MigrationRunner.ts:9


options#

Protected Readonly options: MigrationsOptions

Methods#

getQueries#

PrivategetQueries(migration: Migration, method: up | down): Promise<Query[]>

Parameters:#

NameType
migrationMigration
methodup | down

Returns: Promise<Query[]>

Defined in: packages/migrations/src/MigrationRunner.ts:38


run#

run(migration: Migration, method: up | down): Promise<void>

Parameters:#

NameType
migrationMigration
methodup | down

Returns: Promise<void>

Defined in: packages/migrations/src/MigrationRunner.ts:15


setMasterMigration#

setMasterMigration(trx: any): void

Parameters:#

NameType
trxany

Returns: void

Defined in: packages/migrations/src/MigrationRunner.ts:30


unsetMasterMigration#

unsetMasterMigration(): void

Returns: void

Defined in: packages/migrations/src/MigrationRunner.ts:34

Last updated on by Renovate Bot