|
JSecurity | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jsecurity.session.mgt.quartz.QuartzSessionValidationScheduler
public class QuartzSessionValidationScheduler
An implementation of the SessionValidationScheduler that uses Quartz to schedule a
job to call ValidatingSessionManager.validateSessions() on
a regular basis.
| Field Summary | |
|---|---|
static long |
DEFAULT_SESSION_VALIDATION_INTERVAL
The default interval at which sessions will be validated (1 hour); This can be overridden by calling setSessionValidationInterval(long) |
| Constructor Summary | |
|---|---|
QuartzSessionValidationScheduler()
Default constructor. |
|
QuartzSessionValidationScheduler(ValidatingSessionManager sessionManager)
Constructor that specifies the session manager that should be used for validating sessions. |
|
| Method Summary | |
|---|---|
void |
disableSessionValidation()
Disables the session validation job. |
void |
enableSessionValidation()
Starts session validation by creating a Quartz simple trigger, linking it to the QuartzSessionValidationJob, and scheduling it with the Quartz scheduler. |
protected Scheduler |
getScheduler()
|
boolean |
isEnabled()
Returns true if this Scheduler is enabled and ready to begin validation at the appropriate time,
false otherwise. |
void |
setScheduler(Scheduler scheduler)
|
void |
setSessionManager(ValidatingSessionManager sessionManager)
|
void |
setSessionValidationInterval(long sessionValidationInterval)
Specifies how frequently (in milliseconds) this Scheduler will call the ValidatingSessionManager#validateSessions() method. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final long DEFAULT_SESSION_VALIDATION_INTERVAL
setSessionValidationInterval(long)
| Constructor Detail |
|---|
public QuartzSessionValidationScheduler()
public QuartzSessionValidationScheduler(ValidatingSessionManager sessionManager)
sessionManager - the SessionManager that should be used to validate sessions.| Method Detail |
|---|
protected Scheduler getScheduler()
throws SchedulerException
SchedulerExceptionpublic void setScheduler(Scheduler scheduler)
public void setSessionManager(ValidatingSessionManager sessionManager)
public boolean isEnabled()
SessionValidationSchedulertrue if this Scheduler is enabled and ready to begin validation at the appropriate time,
false otherwise.
It does not indicate if the validation is actually executing at that instant - only that it is prepared
to do so at the appropriate time.
isEnabled in interface SessionValidationSchedulertrue if this Scheduler is enabled and ready to begin validation at the appropriate time,
false otherwise.public void setSessionValidationInterval(long sessionValidationInterval)
ValidatingSessionManager#validateSessions() method.
Unless this method is called, the default value is DEFAULT_SESSION_VALIDATION_INTERVAL.
sessionValidationInterval - public void enableSessionValidation()
QuartzSessionValidationJob, and scheduling it with the Quartz scheduler.
enableSessionValidation in interface SessionValidationSchedulerpublic void disableSessionValidation()
SessionValidationScheduler
disableSessionValidation in interface SessionValidationScheduler
|
JSecurity | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||