public final class CmsThreadStore extends java.lang.Thread
This thread executes all 60 seconds and checks if report threads are still active. A report thread usually waits for a user to get the contents written to the report. However, if the user does not request the reports content (e.g. because the browser was closed), then the report thread becomes abandoned. This Grim Reaper will collect all such abandoned report threads and remove them after further 60 seconds.
Moreover, the Grim Reaper checks for all invalid user sessions that have times out for 5 or more minutes, and removes them as well.
Modifier | Constructor and Description |
---|---|
protected |
CmsThreadStore(CmsSecurityManager securityManager)
Hides the public constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addThread(A_CmsReportThread thread)
Adds a Thread to this Thread store.
|
protected void |
checkPublishQueue()
Checks the publish queue for abandoned publish jobs.
|
protected void |
handleDoomedThreads()
Handles doomed threads.
|
protected void |
persistData()
Takes care of the persistence of data normally held in memory.
|
A_CmsReportThread |
retrieveThread(CmsUUID key)
Retrieves a Thread from this Thread store.
|
void |
run() |
protected void |
shutDown()
Shut down this thread store.
|
protected void |
validateSessions()
Checks for invalid sessions.
|
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
protected CmsThreadStore(CmsSecurityManager securityManager)
securityManager
- needed for scheduling "undercover-jobs"
that increase stability and fault tolerancepublic void addThread(A_CmsReportThread thread)
thread
- the Thread to addpublic A_CmsReportThread retrieveThread(CmsUUID key)
key
- the key of the Thread to retrievepublic void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
Runnable.run()
protected void checkPublishQueue()
protected void handleDoomedThreads()
protected void persistData()
protected void shutDown()
protected void validateSessions()