<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                ### 75.5.1 啟動時執行Flyway數據庫遷移 想要在啟動時自動運行Flyway數據庫遷移,需要將`org.flywaydb:flyway-core`添加到你的classpath下。 遷移是一些`V<VERSION>__<NAME>.sql`格式的腳本(`<VERSION>`是一個下劃線分割的版本號,比如'1'或'2_1')。默認情況下,它們存放在`classpath:db/migration`文件夾中,但你可以使用`flyway.locations`(一個列表)改變它。詳情可參考flyway-core中的`Flyway`類,查看一些可用的配置,比如schemas。Spring Boot在[FlywayProperties](http://github.com/spring-projects/spring-boot/tree/master/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/flyway/FlywayProperties.java)中提供了一個小的屬性集,可用于禁止遷移,或關閉位置檢測。Spring Boot將調用`Flyway.migrate()`執行數據庫遷移,如果想要更多控制可提供一個實現[FlywayMigrationStrategy](https://github.com/spring-projects/spring-boot/tree/v1.4.1.RELEASE/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/flyway/FlywayMigrationStrategy.java)的`@Bean`。 默認情況下,Flyway將自動注入(`@Primary`)`DataSource`到你的上下文,并用它進行數據遷移。如果想使用不同的`DataSource`,你可以創建一個,并將它標記為`@FlywayDataSource`的`@Bean`-如果你這樣做了,且想要兩個數據源,記得創建另一個并將它標記為`@Primary`,或者你可以通過在外部配置文件中設置`flyway.[url,user,password]`來使用Flyway的原生`DataSource`。 這是一個[Flyway示例](http://github.com/spring-projects/spring-boot/tree/master/spring-boot-samples/spring-boot-sample-flyway),你可以作為參考。
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看