Package org.flywaydb.core.api.callback
Enum Class Event
- All Implemented Interfaces:
Serializable
,Comparable<Event>
,Constable
The Flyway lifecycle events that can be handled in callbacks.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionFired after baseline has succeeded.Fired after baseline has failed.Fired after a validate operation has finished.Fired after clean has succeeded.Fired after clean has failed.Fired after a clean operation has finished.Fired after each individual migration that succeeded.Fired after each individual migration that failed.Fired after each individual statement in a migration that succeeded.Fired after each individual statement in a migration that failed.Fired after each individual undo that succeeded.Fired after each individual undo that failed.Fired after each individual statement in an undo migration that succeeded.Fired after each individual statement in an undo migration that failed.Fired after info has succeeded.Fired after info has failed.Fired after an info operation has finished.Fired after migrate has succeeded.Fired after migrate has succeeded, and at least one migration has been applied.Fired after migrate has failed.Fired after a migrate operation has finished.Fired after repair has succeeded.Fired after repair has failed.Fired after a validate operation has finished.Fired after undo has succeeded.Fired after undo has failed.Fired after a validate operation has finished.Fired after validate has succeeded.Fired after validate has failed.Fired after a validate operation has finished.Fired after all versioned migrations are applied.Fired before baseline is executed.Fired before clean is executed.Fired before a connection is created.Fired before each individual migration is executed.Fired before each individual statement in a migration is executed.Fired before each individual undo is executed.Fired before each individual statement in an undo migration is executed.Fired before info is executed.Fired before migrate is executed.Fired before repair is executed.Fired before any repeatable migrations are applied.Fired before undo is executed.Fired before validate is executed.Fired before any non-existent schemas are created. -
Method Summary
-
Enum Constant Details
-
BEFORE_CLEAN
Fired before clean is executed. This event will be fired in a separate transaction from the actual clean operation. -
AFTER_CLEAN
Fired after clean has succeeded. This event will be fired in a separate transaction from the actual clean operation. -
AFTER_CLEAN_ERROR
Fired after clean has failed. This event will be fired in a separate transaction from the actual clean operation. -
BEFORE_MIGRATE
Fired before migrate is executed. This event will be fired in a separate transaction from the actual migrate operation. -
BEFORE_EACH_MIGRATE
Fired before each individual migration is executed. This event will be fired within the same transaction (if any) as the migration and can be used for things like setting up connection parameters that are required by migrations. -
BEFORE_EACH_MIGRATE_STATEMENT
Fired before each individual statement in a migration is executed. This event will be fired within the same transaction (if any) as the migration and can be used for things like asserting a statement complies with policy (for example: no grant statements allowed).Flyway Teams Edition only
-
AFTER_EACH_MIGRATE_STATEMENT
Fired after each individual statement in a migration that succeeded. This event will be fired within the same transaction (if any) as the migration.Flyway Teams Edition only
-
AFTER_EACH_MIGRATE_STATEMENT_ERROR
Fired after each individual statement in a migration that failed. This event will be fired within the same transaction (if any) as the migration.Flyway Teams Edition only
-
AFTER_EACH_MIGRATE
Fired after each individual migration that succeeded. This event will be fired within the same transaction (if any) as the migration. -
AFTER_EACH_MIGRATE_ERROR
Fired after each individual migration that failed. This event will be fired within the same transaction (if any) as the migration. -
BEFORE_REPEATABLES
Fired before any repeatable migrations are applied. This event will be fired in a separate transaction from the actual migrate operation. -
AFTER_VERSIONED
Fired after all versioned migrations are applied. This event will be fired in a separate transaction from the actual migrate operation. -
AFTER_MIGRATE_APPLIED
Fired after migrate has succeeded, and at least one migration has been applied. This event will be fired in a separate transaction from the actual migrate operation. -
AFTER_MIGRATE
Fired after migrate has succeeded. This event will be fired in a separate transaction from the actual migrate operation. -
AFTER_MIGRATE_ERROR
Fired after migrate has failed. This event will be fired in a separate transaction from the actual migrate operation. -
BEFORE_UNDO
Fired before undo is executed. This event will be fired in a separate transaction from the actual undo operation.Flyway Teams Edition only
-
BEFORE_EACH_UNDO
Fired before each individual undo is executed. This event will be fired within the same transaction (if any) as the undo and can be used for things like setting up connection parameters that are required by undo.Flyway Teams Edition only
-
BEFORE_EACH_UNDO_STATEMENT
Fired before each individual statement in an undo migration is executed. This event will be fired within the same transaction (if any) as the migration and can be used for things like asserting a statement complies with policy (for example: no grant statements allowed).Flyway Teams Edition only
-
AFTER_EACH_UNDO_STATEMENT
Fired after each individual statement in an undo migration that succeeded. This event will be fired within the same transaction (if any) as the migration.Flyway Teams Edition only
-
AFTER_EACH_UNDO_STATEMENT_ERROR
Fired after each individual statement in an undo migration that failed. This event will be fired within the same transaction (if any) as the migration.Flyway Teams Edition only
-
AFTER_EACH_UNDO
Fired after each individual undo that succeeded. This event will be fired within the same transaction (if any) as the undo.Flyway Teams Edition only
-
AFTER_EACH_UNDO_ERROR
Fired after each individual undo that failed. This event will be fired within the same transaction (if any) as the undo.Flyway Teams Edition only
-
AFTER_UNDO
Fired after undo has succeeded. This event will be fired in a separate transaction from the actual undo operation.Flyway Teams Edition only
-
AFTER_UNDO_ERROR
Fired after undo has failed. This event will be fired in a separate transaction from the actual undo operation.Flyway Teams Edition only
-
BEFORE_VALIDATE
Fired before validate is executed. This event will be fired in a separate transaction from the actual validate operation. -
AFTER_VALIDATE
Fired after validate has succeeded. This event will be fired in a separate transaction from the actual validate operation. -
AFTER_VALIDATE_ERROR
Fired after validate has failed. This event will be fired in a separate transaction from the actual validate operation. -
BEFORE_BASELINE
Fired before baseline is executed. This event will be fired in a separate transaction from the actual baseline operation. -
AFTER_BASELINE
Fired after baseline has succeeded. This event will be fired in a separate transaction from the actual baseline operation. -
AFTER_BASELINE_ERROR
Fired after baseline has failed. This event will be fired in a separate transaction from the actual baseline operation. -
BEFORE_REPAIR
Fired before repair is executed. This event will be fired in a separate transaction from the actual repair operation. -
AFTER_REPAIR
Fired after repair has succeeded. This event will be fired in a separate transaction from the actual repair operation. -
AFTER_REPAIR_ERROR
Fired after repair has failed. This event will be fired in a separate transaction from the actual repair operation. -
BEFORE_INFO
Fired before info is executed. This event will be fired in a separate transaction from the actual info operation. -
AFTER_INFO
Fired after info has succeeded. This event will be fired in a separate transaction from the actual info operation. -
AFTER_INFO_ERROR
Fired after info has failed. This event will be fired in a separate transaction from the actual info operation. -
AFTER_MIGRATE_OPERATION_FINISH
Fired after a migrate operation has finished. -
AFTER_INFO_OPERATION_FINISH
Fired after an info operation has finished. -
AFTER_CLEAN_OPERATION_FINISH
Fired after a clean operation has finished. -
AFTER_VALIDATE_OPERATION_FINISH
Fired after a validate operation has finished. -
AFTER_UNDO_OPERATION_FINISH
Fired after a validate operation has finished. -
AFTER_REPAIR_OPERATION_FINISH
Fired after a validate operation has finished. -
AFTER_BASELINE_OPERATION_FINISH
Fired after a validate operation has finished. -
CREATE_SCHEMA
Fired before any non-existent schemas are created. -
BEFORE_CONNECT
Fired before a connection is created. These must be arbitrary scripts only (e.g. ps1, cmd, sh etc.)Flyway Teams Edition only
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
fromId
Retrieves the event with this id.- Parameters:
id
- The id.- Returns:
- The event.
null
if not found.
-
toString
-
getId
- Returns:
- The id of an event. Examples:
beforeClean
,afterEachMigrate
, ...
-