/** * Returns a copy of this SynchronizedDescriptiveStatistics instance with the * same internal state. * * @return a copy of this */ @Override public synchronized SynchronizedDescriptiveStatistics copy() { SynchronizedDescriptiveStatistics result = new SynchronizedDescriptiveStatistics(); copy(this, result); return result; }
public StatCollector() { _stats = new SynchronizedDescriptiveStatistics(); _stats.setWindowSize(DEFAULT_WINDOW_SIZE); }
public StatCollector() { _stats = new SynchronizedDescriptiveStatistics(); _stats.setWindowSize(DEFAULT_WINDOW_SIZE); }
/** * Returns a copy of this SynchronizedDescriptiveStatistics instance with the * same internal state. * * @return a copy of this */ @Override public synchronized SynchronizedDescriptiveStatistics copy() { SynchronizedDescriptiveStatistics result = new SynchronizedDescriptiveStatistics(); copy(this, result); return result; }
/** * Runs the iteration of the benchmarks added. * * @param context the execution context * @throws Exception */ private void runIteration(ExecutionContext context) throws Exception { Preconditions.checkArgument(benchmarks != null && !benchmarks.isEmpty(), "No Benchmarks configured"); for (String key : benchmarks.keySet()) { ScalabilityBenchmark benchmark = benchmarks.get(key); if (result.getBenchmarkStatistics(benchmark) == null) { result.addBenchmarkStatistics(benchmark, new SynchronizedDescriptiveStatistics()); } Stopwatch watch = Stopwatch.createStarted(); executeBenchmark(benchmark, context); watch.stop(); result.getBenchmarkStatistics(benchmark).addValue(watch.elapsed(TimeUnit.MILLISECONDS)); if (LOG.isDebugEnabled()) { LOG.debug("Execution time for " + benchmark + "-" + watch.elapsed(TimeUnit.MILLISECONDS)); } } }
String line; int i = 0; DescriptiveStatistics stats = new SynchronizedDescriptiveStatistics(); stats.setWindowSize(dperiods); File f = new File("");
private DescriptiveStatistics runTest(int concurrencyLevel) throws Exception { final SynchronizedDescriptiveStatistics statistics = new SynchronizedDescriptiveStatistics(); if (concurrencyLevel == 1) {
SynchronizedDescriptiveStatistics writeStats = new SynchronizedDescriptiveStatistics();