@ConfigurationProperties(value="redis")
public class RedisHttpSessionConfiguration
extends io.micronaut.session.http.HttpSessionConfiguration
implements io.micronaut.core.util.Toggleable
Constructor and Description |
---|
RedisHttpSessionConfiguration() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getActiveSessionsKey() |
java.nio.charset.Charset |
getCharset() |
java.time.Duration |
getExpiredSessionCheck() |
java.lang.String |
getNamespace() |
java.util.Optional<java.lang.String> |
getServerName() |
java.lang.String |
getSessionCreatedTopic() |
java.util.Optional<java.lang.Class<io.micronaut.core.serialize.ObjectSerializer>> |
getValueSerializer() |
io.micronaut.configuration.lettuce.session.RedisHttpSessionConfiguration.WriteMode |
getWriteMode() |
boolean |
isEnableKeyspaceEvents() |
void |
setActiveSessionsKey(java.lang.String activeSessionsKey)
Sets the key to store active sessions in.
|
void |
setCharset(java.nio.charset.Charset charset)
Sets the charset to use to serialize values.
|
void |
setEnableKeyspaceEvents(boolean enableKeyspaceEvents)
Sets whether keyspace events should be enabled at startup.
|
void |
setExpiredSessionCheck(java.time.Duration expiredSessionCheck)
Sets the duration to check for expired sessions.
|
void |
setNamespace(java.lang.String namespace)
Sets the namespace to use.
|
void |
setServerName(java.lang.String serverName)
Sets the server name.
|
void |
setSessionCreatedTopic(java.lang.String sessionCreatedTopic)
Sets the topic to publish session created events to.
|
void |
setValueSerializer(java.lang.Class<io.micronaut.core.serialize.ObjectSerializer> valueSerializer)
Sets the default value serializer to use.
|
void |
setWriteMode(io.micronaut.configuration.lettuce.session.RedisHttpSessionConfiguration.WriteMode writeMode)
Sets the write mode to use.
|
getCookieDomain, getCookieMaxAge, getCookieName, getCookiePath, getCookieSameSite, getDomainName, getHeaderNames, getPrefix, isBase64Encode, isCookieHttpOnly, isCookieSecure, isRememberMe, setBase64Encode, setCookieDomain, setCookieMaxAge, setCookieName, setCookiePath, setCookieSameSite, setCookieSecure, setDomainName, setHeaderNames, setPrefix, setRememberMe
getExecutorService, getMaxActiveSessions, getMaxInactiveInterval, isPromptExpiration, setExecutorService, setMaxActiveSessions, setMaxInactiveInterval, setPromptExpiration
public java.lang.String getNamespace()
public java.util.Optional<java.lang.String> getServerName()
public java.lang.String getSessionCreatedTopic()
public java.lang.String getActiveSessionsKey()
public java.util.Optional<java.lang.Class<io.micronaut.core.serialize.ObjectSerializer>> getValueSerializer()
ObjectSerializer
type to use for serializing values. Defaults to JdkSerializer
public java.nio.charset.Charset getCharset()
public boolean isEnableKeyspaceEvents()
public io.micronaut.configuration.lettuce.session.RedisHttpSessionConfiguration.WriteMode getWriteMode()
RedisHttpSessionConfiguration.WriteMode
to use. Defaults to RedisHttpSessionConfiguration.WriteMode.BATCH
public java.time.Duration getExpiredSessionCheck()
public void setNamespace(java.lang.String namespace)
namespace
- The namespacepublic void setServerName(java.lang.String serverName)
serverName
- The server namepublic void setSessionCreatedTopic(java.lang.String sessionCreatedTopic)
sessionCreatedTopic
- The session created topicpublic void setActiveSessionsKey(java.lang.String activeSessionsKey)
activeSessionsKey
- The active session keypublic void setValueSerializer(java.lang.Class<io.micronaut.core.serialize.ObjectSerializer> valueSerializer)
valueSerializer
- The value serializerpublic void setCharset(java.nio.charset.Charset charset)
charset
- The default charsetpublic void setEnableKeyspaceEvents(boolean enableKeyspaceEvents)
enableKeyspaceEvents
- True if keyspace event should be enabledpublic void setWriteMode(io.micronaut.configuration.lettuce.session.RedisHttpSessionConfiguration.WriteMode writeMode)
writeMode
- The write modepublic void setExpiredSessionCheck(java.time.Duration expiredSessionCheck)
expiredSessionCheck
- The expired session check