|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.objectweb.jonas.resource.ResourceWorkManager
This class implements the WorkManager interface of the Connector Architecture 1.5 specification.
Field Summary |
Fields inherited from interface javax.resource.spi.work.WorkManager |
IMMEDIATE, INDEFINITE, UNKNOWN |
Constructor Summary | |
ResourceWorkManager(org.objectweb.transaction.jta.TransactionManager tmgr,
int _numThreads,
long _maxExecTime,
org.objectweb.util.monolog.api.Logger mlogger)
|
Method Summary | |
void |
doWork(javax.resource.spi.work.Work work)
Run the specified work object and wait until it completes to return |
void |
doWork(javax.resource.spi.work.Work work,
long timeout,
javax.resource.spi.work.ExecutionContext eCtx,
javax.resource.spi.work.WorkListener wListen)
Run the specified work object and wait until it completes to return |
void |
releasePool()
Used for testing to cause the threads to go away |
void |
scheduleWork(javax.resource.spi.work.Work work)
Run the specified work object and return when it has been accepted |
void |
scheduleWork(javax.resource.spi.work.Work work,
long timeout,
javax.resource.spi.work.ExecutionContext eCtx,
javax.resource.spi.work.WorkListener wListen)
Run the specified work object and return when it has been accepted |
void |
setInited()
Called when the RA is deployed, this will allow the threads to execute the scheduled work objects |
long |
startWork(javax.resource.spi.work.Work work)
Run the specified work object and return when it has been started |
long |
startWork(javax.resource.spi.work.Work work,
long timeout,
javax.resource.spi.work.ExecutionContext eCtx,
javax.resource.spi.work.WorkListener wListen)
Run the specified work object and return when it has started |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ResourceWorkManager(org.objectweb.transaction.jta.TransactionManager tmgr, int _numThreads, long _maxExecTime, org.objectweb.util.monolog.api.Logger mlogger)
Method Detail |
public void doWork(javax.resource.spi.work.Work work) throws javax.resource.spi.work.WorkException
doWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to execute
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic void doWork(javax.resource.spi.work.Work work, long timeout, javax.resource.spi.work.ExecutionContext eCtx, javax.resource.spi.work.WorkListener wListen) throws javax.resource.spi.work.WorkException
doWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to executetimeout
- the max number of milliseconds before Work object must starteCtx
- the ExecutionContext to use for the Work objectwListen
- the WorkListener to use
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic long startWork(javax.resource.spi.work.Work work) throws javax.resource.spi.work.WorkException
startWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to execute
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic long startWork(javax.resource.spi.work.Work work, long timeout, javax.resource.spi.work.ExecutionContext eCtx, javax.resource.spi.work.WorkListener wListen) throws javax.resource.spi.work.WorkException
startWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to executetimeout
- the max number of milliseconds before Work object must starteCtx
- the ExecutionContext to use for the Work objectwListen
- the WorkListener to use
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic void scheduleWork(javax.resource.spi.work.Work work) throws javax.resource.spi.work.WorkException
scheduleWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to execute
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic void scheduleWork(javax.resource.spi.work.Work work, long timeout, javax.resource.spi.work.ExecutionContext eCtx, javax.resource.spi.work.WorkListener wListen) throws javax.resource.spi.work.WorkException
scheduleWork
in interface javax.resource.spi.work.WorkManager
work
- the Work object to executetimeout
- the max number of milliseconds before Work object must starteCtx
- the ExecutionContext to use for the Work objectwListen
- the WorkListener to use
javax.resource.spi.work.WorkException
- if an error occurs during
the acceptance, starting or executionpublic void setInited()
public void releasePool()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |