|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jcs.auxiliary.lateral.LateralCacheMonitor
Used to monitor and repair any failed connection for the lateral cache service. By default the monitor operates in a failure driven mode. That is, it goes into a wait state until there is an error. Upon the notification of a connection error, the monitor changes to operate in a time driven mode. That is, it attempts to recover the connections on a periodic basis. When all failed connections are restored, it changes back to the failure driven mode.
Field Summary | |
private boolean |
alright
|
private static long |
idlePeriod
|
private static LateralCacheMonitor |
instance
|
private static org.apache.commons.logging.Log |
log
|
Constructor Summary | |
private |
LateralCacheMonitor()
Constructor for the LateralCacheMonitor object |
Method Summary | |
private void |
bad()
Sets the "alright" flag to false in a critial section. |
(package private) static LateralCacheMonitor |
getInstance()
Returns the singleton instance; |
void |
notifyError()
Notifies the cache monitor that an error occurred, and kicks off the error recovery process. |
void |
run()
Main processing method for the LateralCacheMonitor object |
static void |
setIdlePeriod(long idlePeriod)
Configures the idle period between repairs. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final org.apache.commons.logging.Log log
private static LateralCacheMonitor instance
private static long idlePeriod
private boolean alright
Constructor Detail |
private LateralCacheMonitor()
Method Detail |
public static void setIdlePeriod(long idlePeriod)
idlePeriod
- The new idlePeriod valuestatic LateralCacheMonitor getInstance()
public void notifyError()
public void run()
run
in interface java.lang.Runnable
private void bad()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |