mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-09-03 04:26:12 +08:00
Upgrade to R2DBC Bom Borca-SR2
Closes gh-32328
This commit is contained in:
parent
24ab4e88cd
commit
d4a88041dc
@ -93,7 +93,7 @@ class R2dbcAutoConfigurationTests {
|
||||
assertThat(context).hasSingleBean(ConnectionFactory.class).hasSingleBean(ConnectionPool.class)
|
||||
.hasSingleBean(R2dbcProperties.class);
|
||||
ConnectionPool connectionPool = context.getBean(ConnectionPool.class);
|
||||
assertThat(connectionPool).hasFieldOrPropertyWithValue("maxAcquireTime", Duration.ofNanos(-1));
|
||||
assertThat(connectionPool).hasFieldOrPropertyWithValue("maxAcquireTime", Duration.ofMillis(-1));
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1407,7 +1407,7 @@ bom {
|
||||
]
|
||||
}
|
||||
}
|
||||
library("R2DBC Bom", "Borca-SR1") {
|
||||
library("R2DBC Bom", "Borca-SR2") {
|
||||
group("io.r2dbc") {
|
||||
imports = [
|
||||
"r2dbc-bom"
|
||||
|
@ -244,6 +244,10 @@ public final class ConnectionFactoryBuilder {
|
||||
.to(builder::maxIdleTime);
|
||||
map.from(options.getValue(PoolingConnectionFactoryProvider.MAX_CREATE_CONNECTION_TIME)).as(this::toDuration)
|
||||
.to(builder::maxCreateConnectionTime);
|
||||
map.from(options.getValue(PoolingConnectionFactoryProvider.MAX_VALIDATION_TIME)).as(this::toDuration)
|
||||
.to(builder::maxValidationTime);
|
||||
map.from(options.getValue(PoolingConnectionFactoryProvider.MIN_IDLE)).as(this::toInteger)
|
||||
.to(builder::minIdle);
|
||||
map.from(options.getValue(PoolingConnectionFactoryProvider.POOL_NAME)).as(this::toString).to(builder::name);
|
||||
map.from(options.getValue(PoolingConnectionFactoryProvider.PRE_RELEASE)).to((function) -> builder
|
||||
.preRelease((Function<? super Connection, ? extends Publisher<Void>>) function));
|
||||
|
@ -265,6 +265,11 @@ class ConnectionFactoryBuilderTests {
|
||||
MAX_CREATE_CONNECTION_TIME(PoolingConnectionFactoryProvider.MAX_CREATE_CONNECTION_TIME, Duration.ofSeconds(10),
|
||||
"maxCreateConnectionTime"),
|
||||
|
||||
MAX_VALIDATION_TIME(PoolingConnectionFactoryProvider.MAX_VALIDATION_TIME, Duration.ofMinutes(4),
|
||||
"maxValidationTime"),
|
||||
|
||||
MIN_IDLE(PoolingConnectionFactoryProvider.MIN_IDLE, 5, "minIdle"),
|
||||
|
||||
POOL_NAME(PoolingConnectionFactoryProvider.POOL_NAME, "testPool", "name"),
|
||||
|
||||
POST_ALLOCATE(PoolingConnectionFactoryProvider.POST_ALLOCATE, mock(Function.class), "postAllocate"),
|
||||
|
Loading…
Reference in New Issue
Block a user