diff --git a/web/src/main/java/org/springframework/security/web/session/ConcurrentSessionFilter.java b/web/src/main/java/org/springframework/security/web/session/ConcurrentSessionFilter.java index e740f3697b..462d271743 100644 --- a/web/src/main/java/org/springframework/security/web/session/ConcurrentSessionFilter.java +++ b/web/src/main/java/org/springframework/security/web/session/ConcurrentSessionFilter.java @@ -64,6 +64,22 @@ public class ConcurrentSessionFilter extends GenericFilterBean { //~ Methods ======================================================================================================== + + /** + * @deprecated Use constructor which injects the SessionRegistry. + */ + public ConcurrentSessionFilter() { + } + + public ConcurrentSessionFilter(SessionRegistry sessionRegistry) { + this(sessionRegistry, null); + } + + public ConcurrentSessionFilter(SessionRegistry sessionRegistry, String expiredUrl) { + this.sessionRegistry = sessionRegistry; + this.expiredUrl = expiredUrl; + } + @Override public void afterPropertiesSet() { Assert.notNull(sessionRegistry, "SessionRegistry required"); @@ -121,10 +137,18 @@ public class ConcurrentSessionFilter extends GenericFilterBean { } } + /** + * @deprecated use constructor injection instead + */ + @Deprecated public void setExpiredUrl(String expiredUrl) { this.expiredUrl = expiredUrl; } + /** + * @deprecated use constructor injection instead + */ + @Deprecated public void setSessionRegistry(SessionRegistry sessionRegistry) { this.sessionRegistry = sessionRegistry; }