Migration of SpringBoot configuration properties


SpringBoot configuration property series

In addition, I attach some personal articles about springboot.


SpringBoot supports two database migration tools, one is flyway and the other is liquibase. It also supports sql script itself and executes the specified script after initializing the data source.


  • flyway.baseline-description
    Description of the baseline version when performing the migration.

  • flyway.baseline-on-migrate
    When the target schema is found to be non-empty and has a table without metadata during migration, whether to automatically perform benchmark migration is false by default.

  • flyway.baseline-version
    When starting the benchmark migration, label the existing schema version, with the default value of 1.

  • flyway.check-location
    Check if the location of the migration script exists, the default is false.

  • flyway.clean-on-validation-error
    If clean is called automatically when a check error is found, false is the default.

  • flyway.enabled
    Whether to turn on flywary, the default is true.

  • flyway.encoding
    Set the encoding for migration, default UTF-8.

  • flyway.ignore-failed-future-migration
    Whether to ignore error migration when reading metadata table, the default is false.

  • flyway.init-sqls
    SQL to be executed when the connection is initialized.

  • flyway.locations
    Location of migration script, default db/migration.

  • flyway.out-of-order
    Whether disorderly migration is allowed is false by default.

  • flyway.password
    The password of the target database.

  • flyway.placeholder-prefix
    Set prefix for each placeholder, default $ {.

  • flyway.placeholder-replacement
    Whether placeholders are to be replaced, the default is true.

  • flyway.placeholder-suffix
    Set suffix for each placeholder, default}.

  • flyway.placeholders.[placeholder name]
    Setting the value of placeholder

  • flyway.schemas
    Set the schema to be migrated by flywary, which is case sensitive, and the default is to connect the default schema.

  • flyway.sql-migration-prefix
    Prefix of migration file, default is v.

  • flyway.sql-migration-separator
    File name separator for migration script, default _ _

  • flyway.sql-migration-suffix
    The suffix of the migration script, which defaults to. sql

  • flyway.table
    The metadata table name used by flyway is schema_version by default

  • flyway.target
    The target version used during migration is latest version by default

  • flyway.url
    The JDBC URL used during migration, if not specified, will use the configured primary data source

  • flyway.user
    User name of the migration database

  • flyway.validate-on-migrate
    Whether to check during migration is true by default.


  • liquibase.change-log
    Path to Change log configuration file, default value is classpath:/db/changelog/db.changelog-master.yaml.

  • liquibase.check-change-log-location
    Whether to insist on whether the change log location exists, the default is true.

  • liquibase.contexts
    Comma-separated list of runtime context.

  • liquibase.default-schema
    The default schema.

  • liquibase.drop-first
    Drop schema first, default is false

  • liquibase.enabled
    Whether to open liquibase, the default is true.

  • liquibase.password
    Target database password

  • liquibase.url
    If the JDBC URL to be migrated is not specified, the configured primary data source will be used.

  • liquibase.user
    Target data username