SpringBoot配置属性系列

另外附上个人关于springboot的一些文章

SpringBoot支持了两种数据库迁移工具,一个是flyway,一个是liquibase。其本身也支持sql script,在初始化数据源之后执行指定的脚本。

flyway

  • flyway.baseline-description
    对执行迁移时基准版本的描述.

  • flyway.baseline-on-migrate
    当迁移时发现目标schema非空,而且带有没有元数据的表时,是否自动执行基准迁移,默认false.

  • flyway.baseline-version
    开始执行基准迁移时对现有的schema的版本打标签,默认值为1.

  • flyway.check-location
    检查迁移脚本的位置是否存在,默认false.

  • flyway.clean-on-validation-error
    当发现校验错误时是否自动调用clean,默认false.

  • flyway.enabled
    是否开启flywary,默认true.

  • flyway.encoding
    设置迁移时的编码,默认UTF-8.

  • flyway.ignore-failed-future-migration
    当读取元数据表时是否忽略错误的迁移,默认false.

  • flyway.init-sqls
    当初始化好连接时要执行的SQL.

  • flyway.locations
    迁移脚本的位置,默认db/migration.

  • flyway.out-of-order
    是否允许无序的迁移,默认false.

  • flyway.password
    目标数据库的密码.

  • flyway.placeholder-prefix
    设置每个placeholder的前缀,默认${.

  • flyway.placeholder-replacement
    placeholders是否要被替换,默认true.

  • flyway.placeholder-suffix
    设置每个placeholder的后缀,默认}.

  • flyway.placeholders.[placeholder name]
    设置placeholder的value

  • flyway.schemas
    设定需要flywary迁移的schema,大小写敏感,默认为连接默认的schema.

  • flyway.sql-migration-prefix
    迁移文件的前缀,默认为V.

  • flyway.sql-migration-separator
    迁移脚本的文件名分隔符,默认__

  • flyway.sql-migration-suffix
    迁移脚本的后缀,默认为.sql

  • flyway.table
    flyway使用的元数据表名,默认为schema_version

  • flyway.target
    迁移时使用的目标版本,默认为latest version

  • flyway.url
    迁移时使用的JDBC URL,如果没有指定的话,将使用配置的主数据源

  • flyway.user
    迁移数据库的用户名

  • flyway.validate-on-migrate
    迁移时是否校验,默认为true.

liquibase

    • liquibase.change-log
      Change log 配置文件的路径,默认值为classpath:/db/changelog/db.changelog-master.yaml

    • liquibase.check-change-log-location
      是否坚持change log的位置是否存在,默认为true.

    • liquibase.contexts
      逗号分隔的运行时context列表.

    • liquibase.default-schema
      默认的schema.

    • liquibase.drop-first
      是否首先drop schema,默认为false

    • liquibase.enabled
      是否开启liquibase,默认为true.

    • liquibase.password
      目标数据库密码

    • liquibase.url
      要迁移的JDBC URL,如果没有指定的话,将使用配置的主数据源.

    • liquibase.user
      目标数据用户名

SpringBoot配置属性之Migration的更多相关文章

  1. SpringBoot配置属性之Server

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  2. SpringBoot配置属性转载地址

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  3. SpringBoot配置属性之其他

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  4. SpringBoot配置属性之Security

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  5. SpringBoot配置属性之MQ

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  6. SpringBoot配置属性之NOSQL

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  7. SpringBoot配置属性之MVC

    SpringBoot配置属性系列 SpringBoot配置属性之MVC SpringBoot配置属性之Server SpringBoot配置属性之DataSource SpringBoot配置属性之N ...

  8. SpringBoot配置属性二

    server配置 server.address指定server绑定的地址 server.compression.enabled是否开启压缩,默认为false. server.compression.e ...

  9. SpringBoot配置属性之Server参数

    server配置server.address指定server绑定的地址 server.compression.enabled是否开启压缩,默认为false. server.compression.ex ...

随机推荐

  1. Overcoming the List View Threshold in SharePoint CAML queries

    From: https://www.codeproject.com/articles/1076854/overcoming-the-list-view-threshold-in-sharepoint- ...

  2. VC++导出具有命名空间的函数

    问题现象 原因分析 解决的方法 1 问题现象 导出具有命名空间的函数和类.源码例如以下: 头文件MiniMFC.h namespace MiniMFC { __declspec(dllexport) ...

  3. Javascript 创建对象的三种方法及比较【转载+整理】

    https://developer.mozilla.org/zh-CN/docs/JavaScript/Guide/Inheritance_and_the_prototype_chain 本文内容 引 ...

  4. Nginx+Lua+Redis构建高并发应用

    一.  源文来自:http://www.ttlsa.com/nginx/nginx-lua-redis/ 二.  预览如下:

  5. 批量删除SQL数据库中的所有表【笔记】

    use OTRJiraDB GO ) begin SELECT @sql='drop table ' + name FROM sysobjects WHERE (type = 'U') ORDER B ...

  6. 查看JAVA的class二进制文件的方法

    hexdump -C filename可以查看二进制文件. 比如java的Test.java public class Test{ public static void main(String[] a ...

  7. 使用Flask+MongoDB实现基于REST的接口简单操作

    目录 前言 1 准备工作 2 具体实现 前言 最近在捣鼓如何使用阿里云服务器搭建一个简单的基于Flask框架的后端接口,刚开始为了图方便,就直接买了一个Windows Server 2008系统服务器 ...

  8. Executor并发框架--线程池,ThreadToolExecutor初步

    Executor存在的目的是提供一种将"任务提交"与"任务如何运行"分离开来的机制.虽然只有一个方法,但是却为灵活且强大的异步任务执行框架提供了基础.它提供了一 ...

  9. 【Zookeeper】源码分析之Watcher机制(二)之WatchManager

    一.前言 前面已经分析了Watcher机制中的第一部分,即在org.apache.zookeeper下的相关类,接着来分析org.apache.zookeeper.server下的WatchManag ...

  10. CentOS 7 安装php5.6,Nginx,Memcached环境及配置

    安装php5.6版本以后不再需要安装Zend Guard,而是用yum命令安装php-opcache及php-pecl-apcu就可以有效的提高php执行速度. 1. 配置yum源 事先确认yum源的 ...