Fix incomplete polish of RedisSessionProperties

Fix polish commit from 919913ae66 to correctly name the property
getter/setters.

See gh-17022
pull/17129/head
Phillip Webb 6 years ago
parent b59dc5bce4
commit e0aa90cf32

@ -54,14 +54,14 @@ class RedisSessionConfiguration {
@Bean
@ConditionalOnMissingBean
public ConfigureRedisAction configureRedisAction(RedisSessionProperties redisSessionProperties) {
switch (redisSessionProperties.getConfigurationStrategy()) {
switch (redisSessionProperties.getConfigureAction()) {
case NOTIFY_KEYSPACE_EVENTS:
return new ConfigureNotifyKeyspaceEventsAction();
case NONE:
return ConfigureRedisAction.NO_OP;
}
throw new IllegalStateException("Unsupported redis configuration strategy '"
+ redisSessionProperties.getConfigurationStrategy() + "'.");
throw new IllegalStateException(
"Unsupported redis configure action '" + redisSessionProperties.getConfigureAction() + "'.");
}
@Configuration

@ -75,12 +75,12 @@ public class RedisSessionProperties {
this.cleanupCron = cleanupCron;
}
public ConfigureAction getConfigurationStrategy() {
public ConfigureAction getConfigureAction() {
return this.configureAction;
}
public void setConfigurationStrategy(ConfigureAction configurationStrategy) {
this.configureAction = configurationStrategy;
public void setConfigureAction(ConfigureAction configureAction) {
this.configureAction = configureAction;
}
/**

@ -89,7 +89,7 @@ class SessionAutoConfigurationRedisTests extends AbstractSessionAutoConfiguratio
}
@Test
void redisSessionConfigureNoStrategy() {
void redisSessionWithConfigureActionNone() {
this.contextRunner.withConfiguration(AutoConfigurations.of(RedisAutoConfiguration.class))
.withPropertyValues("spring.session.store-type=redis", "spring.session.redis.configure-action=none",
"spring.redis.port=" + redis.getFirstMappedPort())
@ -97,7 +97,7 @@ class SessionAutoConfigurationRedisTests extends AbstractSessionAutoConfiguratio
}
@Test
void redisSessionConfigureDefaultStrategy() {
void redisSessionWithDefaultConfigureActionNone() {
this.contextRunner.withConfiguration(AutoConfigurations.of(RedisAutoConfiguration.class))
.withPropertyValues("spring.session.store-type=redis",
"spring.redis.port=" + redis.getFirstMappedPort())
@ -106,7 +106,7 @@ class SessionAutoConfigurationRedisTests extends AbstractSessionAutoConfiguratio
}
@Test
void redisSessionConfigureCustomStrategy() {
void redisSessionWithCustomConfigureRedisActionBean() {
this.contextRunner.withConfiguration(AutoConfigurations.of(RedisAutoConfiguration.class))
.withUserConfiguration(MaxEntriesRedisAction.class)
.withPropertyValues("spring.session.store-type=redis",

Loading…
Cancel
Save