Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
5.10.0
-
None
-
All
Description
Fundamentally there are 2 entities in the plugin managed by different
threads/threadpools:
- the client (generic term for producer of consumer)
- the samplers (throughput + cpu)
These entities can all be configured separately, and the plugin does not
complete until the slowest of these is done. Now, the problem is that
these things all have separate flags, which generally aren't overridden
unless you want to use a really long command line. For example, to get a
perf test that runs for 10 seconds, you have to do the following:
mvn activemq-perf:producer -Dproducer.sendDuration=10000
-DtpSampler.duration=10000 -DtpSampler.rampUpTime=0
-DtpSampler.rampDownTime=0 -DcpuSampler.duration=10000
-DcpuSampler.rampUpTime=0 -DcpuSampler.rampDownTime=0
And all this is before you start adding flags to do anything useful with
it. This is because:
1. sampler threads sleep for the ramp-up time (default 30s); if this
is longer than the producer's send duration then the sampler won't
even start doing anything until |the producer has well and truly
completed
2. the test runs until the longest configured sampler (by default both
throughput + cpu run)
So it's kind of a mess. I'd love to be able to use the principle of
least surprise (and configuration) so that you can just do this:
mvn activemq-perf:producer -Dproducer.sendDuration=10000
mvn activemq-perf:producer -Dproducer.sendType=count
-Dproducer.sendCount=10000