|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 2 (11.1.2.2.0) E17483-03 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
java.lang.Thread
oracle.jbo.mom.LongRunningStatementMonitor
public class LongRunningStatementMonitor
This thread monitors the long running statements and terminates the run away statements. It is started as a Daemon thread. Long running statements are generated by View Objects and Transaction Objects that have positive statement timeout values.
ViewObject.setQueryTimeOut(int)
,
Users can create their own LongRunningStatementHandle
and add it to the monitor using the monitor
API.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
LongRunningStatementMonitor() Creates a new LongRunningStatementMonitor thread. |
Method Summary | |
---|---|
protected void |
finalize() Stop the thread gracefully. |
void |
monitor(LongRunningStatementHandle handle) Adds the handle to the monitored list. |
void |
run() The Thread begins with a loop to iterate over the monitored list of handles and invokes the cancel on expired ones. |
void |
stopGracefully() Terminates the thread gracefully. |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, 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 |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LongRunningStatementMonitor()
LongRunningStatementMonitor
thread.Method Detail |
---|
public void monitor(LongRunningStatementHandle handle)
handle
- a LongRunningStatementHandle
public void run()
cancel
on expired ones. Between each iteration the thread sleeps for a second. To terminate the thread use the stopGracefully
method. Since the thread is a Daemon thread it should not obstruct the shutdown of the JVMrun
in interface java.lang.Runnable
run
in class java.lang.Thread
public void stopGracefully()
protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 2 (11.1.2.2.0) E17483-03 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |