Flyway (flyway
)
The flyway
endpoint provides information about database migrations performed by Flyway.
Retrieving the Migrations
To retrieve the migrations, make a GET
request to /actuator/flyway
, as shown in the following curl-based example:
$ curl 'http://localhost:8080/actuator/flyway' -i -X GET
The resulting response is similar to the following:
HTTP/1.1 200 OK
Content-Type: application/vnd.spring-boot.actuator.v3+json
Content-Length: 515
{
"contexts" : {
"application" : {
"flywayBeans" : {
"flyway" : {
"migrations" : [ {
"type" : "SQL",
"checksum" : -156244537,
"version" : "1",
"description" : "init",
"script" : "V1__init.sql",
"state" : "SUCCESS",
"installedBy" : "SA",
"installedOn" : "2024-10-24T11:37:51.254Z",
"installedRank" : 1,
"executionTime" : 3
} ]
}
}
}
}
}
Response Structure
The response contains details of the application’s Flyway migrations. The following table describes the structure of the response:
Path | Type | Description |
---|---|---|
|
|
Application contexts keyed by id |
|
|
Migrations performed by the Flyway instance, keyed by Flyway bean name. |
|
|
Checksum of the migration, if any. |
|
|
Description of the migration, if any. |
|
|
Execution time in milliseconds of an applied migration. |
|
|
User that installed the applied migration, if any. |
|
|
Timestamp of when the applied migration was installed, if any. |
|
|
Rank of the applied migration, if any. Later migrations have higher ranks. |
|
|
Name of the script used to execute the migration, if any. |
|
|
State of the migration. ( |
|
|
Type of the migration. |
|
|
Version of the database after applying the migration, if any. |
|
|
Id of the parent application context, if any. |