public abstract class AbstractInfinispanSessionRepository extends Object implements org.springframework.session.SessionRepository<org.springframework.session.MapSession>, org.springframework.session.FindByIndexNameSessionRepository<org.springframework.session.MapSession>, org.springframework.context.ApplicationEventPublisherAware, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean
SessionRepository
,
ApplicationEventPublisherAware
,
FindByIndexNameSessionRepository
Modifier and Type | Field and Description |
---|---|
protected AbstractApplicationPublisherBridge |
applicationEventPublisher |
protected SpringCache |
cache |
protected PrincipalNameResolver |
principalNameResolver |
Modifier | Constructor and Description |
---|---|
protected |
AbstractInfinispanSessionRepository(SpringCache cache,
AbstractApplicationPublisherBridge eventsBridge) |
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet() |
org.springframework.session.MapSession |
createSession() |
void |
delete(String id) |
void |
destroy() |
Map<String,org.springframework.session.MapSession> |
findByIndexNameAndIndexValue(String indexName,
String indexValue) |
org.springframework.session.MapSession |
getSession(String id) |
org.springframework.session.MapSession |
getSession(String id,
boolean updateTTL)
Returns session with optional parameter whether or not update time accessed.
|
void |
save(org.springframework.session.MapSession session) |
void |
setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher applicationEventPublisher) |
protected org.springframework.session.MapSession |
updateTTL(org.springframework.session.MapSession session,
boolean updateTTL) |
protected final AbstractApplicationPublisherBridge applicationEventPublisher
protected final SpringCache cache
protected final PrincipalNameResolver principalNameResolver
protected AbstractInfinispanSessionRepository(SpringCache cache, AbstractApplicationPublisherBridge eventsBridge)
public void afterPropertiesSet() throws Exception
afterPropertiesSet
in interface org.springframework.beans.factory.InitializingBean
Exception
public void destroy() throws Exception
destroy
in interface org.springframework.beans.factory.DisposableBean
Exception
public void setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher applicationEventPublisher)
setApplicationEventPublisher
in interface org.springframework.context.ApplicationEventPublisherAware
public org.springframework.session.MapSession createSession()
createSession
in interface org.springframework.session.SessionRepository<org.springframework.session.MapSession>
public void save(org.springframework.session.MapSession session)
save
in interface org.springframework.session.SessionRepository<org.springframework.session.MapSession>
public org.springframework.session.MapSession getSession(String id)
getSession
in interface org.springframework.session.SessionRepository<org.springframework.session.MapSession>
public org.springframework.session.MapSession getSession(String id, boolean updateTTL)
id
- Session ID.updateTTL
- true
if time accessed needs to be updated.null
if it doesn't exist.protected org.springframework.session.MapSession updateTTL(org.springframework.session.MapSession session, boolean updateTTL)
public void delete(String id)
delete
in interface org.springframework.session.SessionRepository<org.springframework.session.MapSession>
public Map<String,org.springframework.session.MapSession> findByIndexNameAndIndexValue(String indexName, String indexValue)
findByIndexNameAndIndexValue
in interface org.springframework.session.FindByIndexNameSessionRepository<org.springframework.session.MapSession>
Copyright © 2018 JBoss, a division of Red Hat. All rights reserved.