Polish SessionRepository javadoc

Clarifies that getSession updates expiration, but it must be saved for
the expiration to be persisted.
This commit is contained in:
Rob Winch
2014-11-10 13:39:24 -06:00
parent 0f8c3b8d07
commit 2a558885ad

View File

@@ -48,6 +48,13 @@ public interface SessionRepository<S extends Session> {
/**
* Gets the {@link Session} by the {@link Session#getId()} or null if no {@link Session} is found.
*
* <p>
* If the {@link Session} extends {@link ExpiringSession}, then {@link ExpiringSession#getLastAccessedTime()} will be
* updated on the returned object. In order to persist this change, {@link #save(Session)} must be invoked on the returned
* instance.
* </p>
*
* @param id the {@link org.springframework.session.Session#getId()} to lookup
* @return the {@link Session} by the {@link Session#getId()} or null if no {@link Session} is found.
*/