@Configuration(proxyBeanMethods=false) @EnableScheduling public class RedisHttpSessionConfiguration extends SpringHttpSessionConfiguration implements org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.context.EmbeddedValueResolverAware, org.springframework.context.annotation.ImportAware, org.springframework.scheduling.annotation.SchedulingConfigurer
SessionRepositoryFilter
as a bean named
springSessionRepositoryFilter
. In order to use this a single
RedisConnectionFactory
must be exposed as a Bean.EnableRedisHttpSession
Constructor and Description |
---|
RedisHttpSessionConfiguration() |
Modifier and Type | Method and Description |
---|---|
void |
configureTasks(org.springframework.scheduling.config.ScheduledTaskRegistrar taskRegistrar) |
org.springframework.beans.factory.InitializingBean |
enableRedisKeyspaceNotificationsInitializer() |
RedisOperationsSessionRepository |
sessionRepository() |
void |
setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher applicationEventPublisher) |
void |
setBeanClassLoader(java.lang.ClassLoader classLoader) |
void |
setCleanupCron(java.lang.String cleanupCron) |
void |
setConfigureRedisAction(ConfigureRedisAction configureRedisAction)
Sets the action to perform for configuring Redis.
|
void |
setDefaultRedisSerializer(org.springframework.data.redis.serializer.RedisSerializer<java.lang.Object> defaultRedisSerializer) |
void |
setEmbeddedValueResolver(org.springframework.util.StringValueResolver resolver) |
void |
setImportMetadata(org.springframework.core.type.AnnotationMetadata importMetadata) |
void |
setMaxInactiveIntervalInSeconds(int maxInactiveIntervalInSeconds) |
void |
setRedisConnectionFactory(org.springframework.beans.factory.ObjectProvider<org.springframework.data.redis.connection.RedisConnectionFactory> springSessionRedisConnectionFactory,
org.springframework.beans.factory.ObjectProvider<org.springframework.data.redis.connection.RedisConnectionFactory> redisConnectionFactory) |
void |
setRedisFlushMode(RedisFlushMode redisFlushMode) |
void |
setRedisNamespace(java.lang.String namespace) |
void |
setRedisSubscriptionExecutor(java.util.concurrent.Executor redisSubscriptionExecutor) |
void |
setRedisTaskExecutor(java.util.concurrent.Executor redisTaskExecutor) |
org.springframework.data.redis.listener.RedisMessageListenerContainer |
springSessionRedisMessageListenerContainer(RedisOperationsSessionRepository sessionRepository) |
init, sessionEventHttpSessionListenerAdapter, setApplicationContext, setCookieSerializer, setHttpSessionIdResolver, setHttpSessionListeners, setServletContext, springSessionRepositoryFilter
@Bean public RedisOperationsSessionRepository sessionRepository()
@Bean public org.springframework.data.redis.listener.RedisMessageListenerContainer springSessionRedisMessageListenerContainer(RedisOperationsSessionRepository sessionRepository)
@Bean public org.springframework.beans.factory.InitializingBean enableRedisKeyspaceNotificationsInitializer()
public void setMaxInactiveIntervalInSeconds(int maxInactiveIntervalInSeconds)
public void setRedisNamespace(java.lang.String namespace)
public void setRedisFlushMode(RedisFlushMode redisFlushMode)
public void setCleanupCron(java.lang.String cleanupCron)
@Autowired(required=false) public void setConfigureRedisAction(ConfigureRedisAction configureRedisAction)
configureRedisAction
- the configureRedis to set. The default is
ConfigureNotifyKeyspaceEventsAction
.@Autowired public void setRedisConnectionFactory(@SpringSessionRedisConnectionFactory org.springframework.beans.factory.ObjectProvider<org.springframework.data.redis.connection.RedisConnectionFactory> springSessionRedisConnectionFactory, org.springframework.beans.factory.ObjectProvider<org.springframework.data.redis.connection.RedisConnectionFactory> redisConnectionFactory)
@Autowired(required=false) @Qualifier(value="springSessionDefaultRedisSerializer") public void setDefaultRedisSerializer(org.springframework.data.redis.serializer.RedisSerializer<java.lang.Object> defaultRedisSerializer)
@Autowired public void setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher applicationEventPublisher)
@Autowired(required=false) @Qualifier(value="springSessionRedisTaskExecutor") public void setRedisTaskExecutor(java.util.concurrent.Executor redisTaskExecutor)
@Autowired(required=false) @Qualifier(value="springSessionRedisSubscriptionExecutor") public void setRedisSubscriptionExecutor(java.util.concurrent.Executor redisSubscriptionExecutor)
public void setBeanClassLoader(java.lang.ClassLoader classLoader)
setBeanClassLoader
in interface org.springframework.beans.factory.BeanClassLoaderAware
public void setEmbeddedValueResolver(org.springframework.util.StringValueResolver resolver)
setEmbeddedValueResolver
in interface org.springframework.context.EmbeddedValueResolverAware
public void setImportMetadata(org.springframework.core.type.AnnotationMetadata importMetadata)
setImportMetadata
in interface org.springframework.context.annotation.ImportAware
public void configureTasks(org.springframework.scheduling.config.ScheduledTaskRegistrar taskRegistrar)
configureTasks
in interface org.springframework.scheduling.annotation.SchedulingConfigurer