Redgate Summit – The Database DevOps Transformation Watch now
PASS Data Community Summit logo

PASS Data Community Summit

A hybrid conference in Seattle and online

15-18 November

Flyway Documentation

This documentation site is not updated. The new documentation can now be found on documentation.red-gate.com

Poll

Skip Executing Migrations

Flyway Teams

Description

Whether Flyway should skip migration execution. The remainder of the operation will run as normal - including updating the schema history table, callbacks, and so on.

skipExecutingMigrations essentially allows you to mimic a migration being executed, because the schema history table is still updated as normal.

skipExecutingMigrations can be used to bring an out-of-process change into Flyway’s change control process. For instance, a script run against the database outside of Flyway (like a hotfix) can be turned into a migration. The hotfix migration can be deployed with Flyway with skipExecutingMigrations=true. The schema history table will be updated with the new migration, but the script itself won’t be executed again.

skipExecutingMigrations can be used with with cherryPick to skip specific migrations.

Default

false

Usage

Commandline

./flyway -skipExecutingMigrations="true" migrate

Configuration File

flyway.skipExecutingMigrations=true

Environment Variable

FLYWAY_SKIP_EXECUTING_MIGRATIONS=true

API

Flyway.configure()
    .skipExecutingMigrations(true)
    .load()

Gradle

flyway {
    skipExecutingMigrations = true
}

Maven

<configuration>
    <skipExecutingMigrations>true</skipExecutingMigrations>
</configuration>

See the following articles for additional information on skipExecutingMigrations along with examples and use cases.