Annotation Type EnableInfinispanRemoteHttpSession
@Retention(RUNTIME)
@Target(TYPE)
@Documented
@Import(InfinispanRemoteHttpSessionConfiguration.class)
@Configuration
public @interface EnableInfinispanRemoteHttpSession
Add this annotation to a
@Configuration
class to expose the SessionRepositoryFilter as a bean named
"springSessionRepositoryFilter" and backed on Infinispan.
The configuration requires creating a SpringCache
(for either remote or
embedded configuration). Here's an example:
@Configuration
@EnableInfinispanRemoteHttpSession
public class InfinispanConfiguration {
@Bean
public SpringRemoteCacheManagerFactoryBean springCache() {
return new SpringRemoteCacheManagerFactoryBean();
}
}
Configuring advanced features requires putting everything together manually or extending
InfinispanRemoteHttpSessionConfiguration
.- Since:
- 9.0
- Author:
- Sebastian Ćaskawiec
- See Also:
-
EnableSpringHttpSession
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionCache name used for storing session data.int
This is the session timeout in seconds. -
Field Summary
-
Field Details
-
DEFAULT_CACHE_NAME
- See Also:
-
-
Element Details
-
maxInactiveIntervalInSeconds
int maxInactiveIntervalInSecondsThis is the session timeout in seconds. By default, it is set to 1800 seconds (30 minutes). This should be a non-negative integer.- Returns:
- the seconds a session can be inactive before expiring
- Default:
- 1800
-
cacheName
String cacheNameCache name used for storing session data.- Returns:
- the cache name for storing data.
- Default:
- "sessions"
-