What are the possible values of spring.datasource.initialization-mode?

后端 未结 2 1362
伪装坚强ぢ
伪装坚强ぢ 2021-02-19 10:48

I am configuring a database in Spring JPA and I want to know what the possible values are of spring.datasource.initialization-mode. I found this page with common pr

2条回答
  •  谎友^
    谎友^ (楼主)
    2021-02-19 11:23

    Forgive me for butting in almost a year late. After having faced a similar problem as explained by Christine, I decided to take the clue and begin searching in the source. It would appear that the following is detailed in the link here https://docs.spring.io/spring-boot/docs/current/api/org/springframework/boot/jdbc/DataSourceInitializationMode.html :

    Enum Constant Summary Enum Constants

    Enum Constant and Description

    ALWAYS Always initialize the datasource.

    EMBEDDED Only initialize an embedded datasource.

    NEVER Do not initialize the datasource.

提交回复
热议问题