Merge branch '2.7.x'

This commit is contained in:
Stephane Nicoll 2022-03-18 15:08:28 +01:00
commit 39b6f2bd7d
5 changed files with 47 additions and 27 deletions

View File

@ -188,6 +188,9 @@ public class FlywayAutoConfiguration {
map.from(properties.getPlaceholders()).to(configuration::placeholders); map.from(properties.getPlaceholders()).to(configuration::placeholders);
map.from(properties.getPlaceholderPrefix()).to(configuration::placeholderPrefix); map.from(properties.getPlaceholderPrefix()).to(configuration::placeholderPrefix);
map.from(properties.getPlaceholderSuffix()).to(configuration::placeholderSuffix); map.from(properties.getPlaceholderSuffix()).to(configuration::placeholderSuffix);
// No method reference for compatibility with Flyway version < 8.0
map.from(properties.getPlaceholderSeparator())
.to((placeHolderSeparator) -> configuration.placeholderSeparator(placeHolderSeparator));
map.from(properties.isPlaceholderReplacement()).to(configuration::placeholderReplacement); map.from(properties.isPlaceholderReplacement()).to(configuration::placeholderReplacement);
map.from(properties.getSqlMigrationPrefix()).to(configuration::sqlMigrationPrefix); map.from(properties.getSqlMigrationPrefix()).to(configuration::sqlMigrationPrefix);
map.from(properties.getSqlMigrationSuffixes()).as(StringUtils::toStringArray) map.from(properties.getSqlMigrationSuffixes()).as(StringUtils::toStringArray)

View File

@ -146,6 +146,11 @@ public class FlywayProperties {
*/ */
private String placeholderSuffix = "}"; private String placeholderSuffix = "}";
/**
* Separator of default placeholders.
*/
private String placeholderSeparator;
/** /**
* Perform placeholder replacement in migration scripts. * Perform placeholder replacement in migration scripts.
*/ */
@ -538,6 +543,14 @@ public class FlywayProperties {
this.placeholderSuffix = placeholderSuffix; this.placeholderSuffix = placeholderSuffix;
} }
public String getPlaceholderSeparator() {
return this.placeholderSeparator;
}
public void setPlaceholderSeparator(String placeholderSeparator) {
this.placeholderSeparator = placeholderSeparator;
}
public boolean isPlaceholderReplacement() { public boolean isPlaceholderReplacement() {
return this.placeholderReplacement; return this.placeholderReplacement;
} }

View File

@ -923,6 +923,10 @@
"name": "spring.flyway.lock-retry-count", "name": "spring.flyway.lock-retry-count",
"defaultValue": 50 "defaultValue": 50
}, },
{
"name": "spring.flyway.placeholder-separator",
"defaultValue": ":"
},
{ {
"name": "spring.flyway.script-placeholder-prefix", "name": "spring.flyway.script-placeholder-prefix",
"defaultValue": "FP__" "defaultValue": "FP__"

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2021 the original author or authors. * Copyright 2012-2022 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -292,7 +292,7 @@ class Neo4jAutoConfigurationTests {
Config.TrustStrategy trustStrategy = mapDriverConfig(properties).trustStrategy(); Config.TrustStrategy trustStrategy = mapDriverConfig(properties).trustStrategy();
assertThat(trustStrategy.strategy()) assertThat(trustStrategy.strategy())
.isEqualTo(Config.TrustStrategy.Strategy.TRUST_CUSTOM_CA_SIGNED_CERTIFICATES); .isEqualTo(Config.TrustStrategy.Strategy.TRUST_CUSTOM_CA_SIGNED_CERTIFICATES);
assertThat(trustStrategy.certFile()).isEqualTo(certFile); assertThat(trustStrategy.certFiles()).containsOnly(certFile);
} }
@Test @Test

View File

@ -62,7 +62,7 @@ bom {
] ]
} }
} }
library("Awaitility", "4.1.1") { library("Awaitility", "4.2.0") {
group("org.awaitility") { group("org.awaitility") {
modules = [ modules = [
"awaitility", "awaitility",
@ -97,7 +97,7 @@ bom {
] ]
} }
} }
library("Cassandra Driver", "4.13.0") { library("Cassandra Driver", "4.14.0") {
group("com.datastax.oss") { group("com.datastax.oss") {
imports = [ imports = [
"java-driver-bom" "java-driver-bom"
@ -153,7 +153,7 @@ bom {
] ]
} }
} }
library("Couchbase Client", "3.2.5") { library("Couchbase Client", "3.2.6") {
group("com.couchbase.client") { group("com.couchbase.client") {
modules = [ modules = [
"java-client" "java-client"
@ -184,14 +184,14 @@ bom {
] ]
} }
} }
library("Dropwizard Metrics", "4.2.8") { library("Dropwizard Metrics", "4.2.9") {
group("io.dropwizard.metrics") { group("io.dropwizard.metrics") {
imports = [ imports = [
"metrics-bom" "metrics-bom"
] ]
} }
} }
library("Elasticsearch", "7.17.0") { library("Elasticsearch", "7.17.1") {
group("org.elasticsearch") { group("org.elasticsearch") {
modules = [ modules = [
"elasticsearch" "elasticsearch"
@ -229,7 +229,7 @@ bom {
] ]
} }
} }
library("Flyway", "8.5.1") { library("Flyway", "8.5.4") {
group("org.flywaydb") { group("org.flywaydb") {
modules = [ modules = [
"flyway-core", "flyway-core",
@ -314,7 +314,7 @@ bom {
] ]
} }
} }
library("Hazelcast", "5.1") { library("Hazelcast", "5.1.1") {
group("com.hazelcast") { group("com.hazelcast") {
modules = [ modules = [
"hazelcast", "hazelcast",
@ -330,7 +330,7 @@ bom {
] ]
} }
} }
library("Hibernate", "5.6.5.Final") { library("Hibernate", "5.6.7.Final") {
group("org.hibernate") { group("org.hibernate") {
modules = [ modules = [
"hibernate-c3p0", "hibernate-c3p0",
@ -372,7 +372,7 @@ bom {
] ]
} }
} }
library("HtmlUnit", "2.58.0") { library("HtmlUnit", "2.59.0") {
group("net.sourceforge.htmlunit") { group("net.sourceforge.htmlunit") {
modules = [ modules = [
"htmlunit" { "htmlunit" {
@ -438,7 +438,7 @@ bom {
] ]
} }
} }
library("Jackson Bom", "2.13.1") { library("Jackson Bom", "2.13.2") {
group("com.fasterxml.jackson") { group("com.fasterxml.jackson") {
imports = [ imports = [
"jackson-bom" "jackson-bom"
@ -784,7 +784,7 @@ bom {
] ]
} }
} }
library("Liquibase", "4.8.0") { library("Liquibase", "4.9.0") {
group("org.liquibase") { group("org.liquibase") {
modules = [ modules = [
"liquibase-cdi", "liquibase-cdi",
@ -795,14 +795,14 @@ bom {
] ]
} }
} }
library("Log4j2", "2.17.1") { library("Log4j2", "2.17.2") {
group("org.apache.logging.log4j") { group("org.apache.logging.log4j") {
imports = [ imports = [
"log4j-bom" "log4j-bom"
] ]
} }
} }
library("Logback", "1.2.10") { library("Logback", "1.2.11") {
group("ch.qos.logback") { group("ch.qos.logback") {
modules = [ modules = [
"logback-access", "logback-access",
@ -846,14 +846,14 @@ bom {
] ]
} }
} }
library("Maven Compiler Plugin", "3.10.0") { library("Maven Compiler Plugin", "3.10.1") {
group("org.apache.maven.plugins") { group("org.apache.maven.plugins") {
plugins = [ plugins = [
"maven-compiler-plugin" "maven-compiler-plugin"
] ]
} }
} }
library("Maven Dependency Plugin", "3.2.0") { library("Maven Dependency Plugin", "3.3.0") {
group("org.apache.maven.plugins") { group("org.apache.maven.plugins") {
plugins = [ plugins = [
"maven-dependency-plugin" "maven-dependency-plugin"
@ -970,7 +970,7 @@ bom {
] ]
} }
} }
library("Mockito", "4.3.1") { library("Mockito", "4.4.0") {
group("org.mockito") { group("org.mockito") {
modules = [ modules = [
"mockito-core", "mockito-core",
@ -1013,14 +1013,14 @@ bom {
] ]
} }
} }
library("Neo4j Java Driver", "4.4.3") { library("Neo4j Java Driver", "4.4.5") {
group("org.neo4j.driver") { group("org.neo4j.driver") {
modules = [ modules = [
"neo4j-java-driver" "neo4j-java-driver"
] ]
} }
} }
library("Netty", "4.1.74.Final") { library("Netty", "4.1.75.Final") {
group("io.netty") { group("io.netty") {
imports = [ imports = [
"netty-bom" "netty-bom"
@ -1081,7 +1081,7 @@ bom {
] ]
} }
} }
library("R2DBC Bom", "Borca-RELEASE") { library("R2DBC Bom", "Borca-SR1") {
group("io.r2dbc") { group("io.r2dbc") {
imports = [ imports = [
"r2dbc-bom" "r2dbc-bom"
@ -1095,7 +1095,7 @@ bom {
] ]
} }
} }
library("Rabbit Stream Client", "0.4.0") { library("Rabbit Stream Client", "0.5.0") {
group("com.rabbitmq") { group("com.rabbitmq") {
modules = [ modules = [
"stream-client" "stream-client"
@ -1226,14 +1226,14 @@ bom {
] ]
} }
} }
library("Selenium HtmlUnit", "3.58.0") { library("Selenium HtmlUnit", "3.59.0") {
group("org.seleniumhq.selenium") { group("org.seleniumhq.selenium") {
modules = [ modules = [
"htmlunit-driver" "htmlunit-driver"
] ]
} }
} }
library("SendGrid", "4.8.3") { library("SendGrid", "4.9.0") {
group("com.sendgrid") { group("com.sendgrid") {
modules = [ modules = [
"sendgrid-java" "sendgrid-java"
@ -1373,7 +1373,7 @@ bom {
] ]
} }
} }
library("Spring Retry", "1.3.1") { library("Spring Retry", "1.3.2") {
group("org.springframework.retry") { group("org.springframework.retry") {
modules = [ modules = [
"spring-retry" "spring-retry"
@ -1472,7 +1472,7 @@ bom {
] ]
} }
} }
library("UnboundID LDAPSDK", "6.0.3") { library("UnboundID LDAPSDK", "6.0.4") {
group("com.unboundid") { group("com.unboundid") {
modules = [ modules = [
"unboundid-ldapsdk" "unboundid-ldapsdk"
@ -1488,7 +1488,7 @@ bom {
] ]
} }
} }
library("Versions Maven Plugin", "2.9.0") { library("Versions Maven Plugin", "2.10.0") {
group("org.codehaus.mojo") { group("org.codehaus.mojo") {
plugins = [ plugins = [
"versions-maven-plugin" "versions-maven-plugin"