Skip to content

Commit 1295477

Browse files
committed
Polish
1 parent f4d892c commit 1295477

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

spring-boot-project/spring-boot-autoconfigure/src/main/resources/META-INF/additional-spring-configuration-metadata.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2941,15 +2941,15 @@
29412941
},
29422942
{
29432943
"value": "regex:",
2944-
"description": "Read from any node that has RedisURI matching with the given pattern"
2944+
"description": "Read from any node that has RedisURI matching with the given pattern."
29452945
},
29462946
{
29472947
"value": "replica",
29482948
"description": "Read from the replica only."
29492949
},
29502950
{
29512951
"value": "replica-preferred",
2952-
"description": "Read preferred from replica and fall back to upstream if no replica is available"
2952+
"description": "Read preferred from replica and fall back to upstream if no replica is available."
29532953
},
29542954
{
29552955
"value": "subnet:",

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/redis/RedisAutoConfigurationTests.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -127,14 +127,15 @@ void testOverrideRedisConfiguration() {
127127
@MethodSource
128128
void shouldConfigureLettuceReadFromProperty(String type, ReadFrom readFrom) {
129129
this.contextRunner.withPropertyValues("spring.data.redis.lettuce.read-from:" + type).run((context) -> {
130-
LettuceConnectionFactory cf = context.getBean(LettuceConnectionFactory.class);
131-
assertThat(cf.getClientConfiguration().getReadFrom()).hasValue(readFrom);
130+
LettuceConnectionFactory factory = context.getBean(LettuceConnectionFactory.class);
131+
LettuceClientConfiguration configuration = factory.getClientConfiguration();
132+
assertThat(configuration.getReadFrom()).hasValue(readFrom);
132133
});
133134
}
134135

135136
@Test
136137
@Disabled("Lettuce 6.5.0.RELEASE")
137-
void shouldConfigureLettuceReadFromPropertyRegexType() {
138+
void shouldConfigureLettuceRegexReadFromProperty() {
138139
RedisClusterNode node1 = createRedisNode("redis-node-1.region-1.example.com");
139140
RedisClusterNode node2 = createRedisNode("redis-node-2.region-1.example.com");
140141
RedisClusterNode node3 = createRedisNode("redis-node-1.region-2.example.com");
@@ -152,7 +153,7 @@ void shouldConfigureLettuceReadFromPropertyRegexType() {
152153

153154
@Test
154155
@Disabled("Lettuce 6.5.0.RELEASE")
155-
void shouldConfigureLettuceReadFromPropertySubnetType() {
156+
void shouldConfigureLettuceSubnetReadFromProperty() {
156157
RedisClusterNode nodeInSubnetIpv4 = createRedisNode("192.0.2.1");
157158
RedisClusterNode nodeNotInSubnetIpv4 = createRedisNode("198.51.100.1");
158159
RedisClusterNode nodeInSubnetIpv6 = createRedisNode("2001:db8:abcd:0000::1");

0 commit comments

Comments
 (0)