|
|
|
@ -38,6 +38,7 @@ import org.springframework.boot.autoconfigure.jdbc.DataSourceProperties;
|
|
|
|
|
import org.springframework.boot.autoconfigure.jdbc.JdbcOperationsDependsOnPostProcessor;
|
|
|
|
|
import org.springframework.boot.autoconfigure.jdbc.NamedParameterJdbcOperationsDependsOnPostProcessor;
|
|
|
|
|
import org.springframework.boot.autoconfigure.liquibase.LiquibaseAutoConfiguration.LiquibaseDataSourceCondition;
|
|
|
|
|
import org.springframework.boot.autoconfigure.liquibase.LiquibaseAutoConfiguration.LiquibaseEntityManagerFactoryDependsOnPostProcessor;
|
|
|
|
|
import org.springframework.boot.autoconfigure.liquibase.LiquibaseAutoConfiguration.LiquibaseJdbcOperationsDependsOnPostProcessor;
|
|
|
|
|
import org.springframework.boot.autoconfigure.liquibase.LiquibaseAutoConfiguration.LiquibaseNamedParameterJdbcOperationsDependsOnPostProcessor;
|
|
|
|
|
import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration;
|
|
|
|
@ -70,7 +71,8 @@ import org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean;
|
|
|
|
|
@ConditionalOnProperty(prefix = "spring.liquibase", name = "enabled", matchIfMissing = true)
|
|
|
|
|
@Conditional(LiquibaseDataSourceCondition.class)
|
|
|
|
|
@AutoConfigureAfter({ DataSourceAutoConfiguration.class, HibernateJpaAutoConfiguration.class })
|
|
|
|
|
@Import({ LiquibaseJdbcOperationsDependsOnPostProcessor.class,
|
|
|
|
|
@Import({ LiquibaseEntityManagerFactoryDependsOnPostProcessor.class,
|
|
|
|
|
LiquibaseJdbcOperationsDependsOnPostProcessor.class,
|
|
|
|
|
LiquibaseNamedParameterJdbcOperationsDependsOnPostProcessor.class })
|
|
|
|
|
public class LiquibaseAutoConfiguration {
|
|
|
|
|
|
|
|
|
@ -83,7 +85,6 @@ public class LiquibaseAutoConfiguration {
|
|
|
|
|
@Configuration(proxyBeanMethods = false)
|
|
|
|
|
@ConditionalOnMissingBean(SpringLiquibase.class)
|
|
|
|
|
@EnableConfigurationProperties({ DataSourceProperties.class, LiquibaseProperties.class })
|
|
|
|
|
@Import(LiquibaseEntityManagerFactoryDependsOnPostProcessor.class)
|
|
|
|
|
public static class LiquibaseConfiguration {
|
|
|
|
|
|
|
|
|
|
private final LiquibaseProperties properties;
|
|
|
|
|