|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.commons.performance.ClientThread org.apache.commons.performance.pool.PoolClientThread
public class PoolClientThread
Client thread that borrows and returns objects from a pool in a loop.
See ClientThread javadoc
for a description
of how times between requests are computed.
Field Summary |
---|
Fields inherited from class org.apache.commons.performance.ClientThread |
---|
logger, PEAK_LOAD, RAMPING_DOWN, RAMPING_UP, stats, TROUGH_LOAD |
Constructor Summary | |
---|---|
PoolClientThread(long iterations,
long minDelay,
long maxDelay,
double sigma,
String delayType,
long rampPeriod,
long peakPeriod,
long troughPeriod,
String cycleType,
String rampType,
Logger logger,
Statistics stats,
KeyedObjectPool keyedPool,
double samplingRate)
Create a pool client thread for a KeyedObjectPool. |
|
PoolClientThread(long iterations,
long minDelay,
long maxDelay,
double sigma,
String delayType,
long rampPeriod,
long peakPeriod,
long troughPeriod,
String cycleType,
String rampType,
Logger logger,
Statistics stats,
ObjectPool pool,
double samplingRate)
Create a pool client thread for an ObjectPool. |
Method Summary | |
---|---|
protected void |
cleanUp()
Executed in finally block of iteration try-catch |
void |
execute()
Borrow and return |
protected void |
finish()
Executed once after the run finishes |
Methods inherited from class org.apache.commons.performance.ClientThread |
---|
adjustState, computeCyclicDelay, getCycleState, getCycleType, getDelayType, getIterations, getLastMean, getMaxDelay, getMinDelay, getNumErrors, getNumMisses, getPeakPeriod, getPeriodStart, getRampPeriod, getRampType, getSigma, getStartTime, getStats, getTroughPeriod, init, nextDelay, run, setCycleState, setDelayType, setLastMean, setMaxDelay, setMinDelay, setNumErrors, setNumMisses, setPeakPeriod, setPeriodStart, setRampPeriod, setRampType, setSigma, setStartTime, setTroughPeriod, setUp |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PoolClientThread(long iterations, long minDelay, long maxDelay, double sigma, String delayType, long rampPeriod, long peakPeriod, long troughPeriod, String cycleType, String rampType, Logger logger, Statistics stats, ObjectPool pool, double samplingRate)
iterations
- number of iterationsminDelay
- minimum mean time between client requestsmaxDelay
- maximum mean time between client requestsdelayType
- distribution of time between client requestsrampPeriod
- ramp period of cycle for cyclic loadpeakPeriod
- peak period of cycle for cyclic loadtroughPeriod
- trough period of cycle for cyclic loadcycleType
- type of cycle for mean delayrampType
- type of ramp (linear or random jumps)logger
- common logger shared by all clientsstats
- Statistics containerpool
- ObjectPoolpublic PoolClientThread(long iterations, long minDelay, long maxDelay, double sigma, String delayType, long rampPeriod, long peakPeriod, long troughPeriod, String cycleType, String rampType, Logger logger, Statistics stats, KeyedObjectPool keyedPool, double samplingRate)
iterations
- number of iterationsminDelay
- minimum mean time between client requestsmaxDelay
- maximum mean time between client requestsdelayType
- distribution of time between client requestsrampPeriod
- ramp period of cycle for cyclic loadpeakPeriod
- peak period of cycle for cyclic loadtroughPeriod
- trough period of cycle for cyclic loadcycleType
- type of cycle for mean delayrampType
- type of ramp (linear or random jumps)logger
- common logger shared by all clientsstats
- Statistics containerkeyedPool
- KeyedObjectPoolMethod Detail |
---|
public void execute() throws Exception
execute
in class ClientThread
Exception
protected void cleanUp() throws Exception
ClientThread
cleanUp
in class ClientThread
Exception
protected void finish() throws Exception
ClientThread
finish
in class ClientThread
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |