MCPcopy Create free account
hub / github.com/cmu-db/benchbase / getInterval

Method getInterval

src/main/java/com/oltpbenchmark/ThreadBench.java:383–390  ·  view source on GitHub ↗
(double lowestRate, Phase.Arrival arrival)

Source from the content-addressed store, hash-verified

381 }
382
383 private long getInterval(double lowestRate, Phase.Arrival arrival) {
384 // TODO Auto-generated method stub
385 if (arrival == Phase.Arrival.POISSON) {
386 return (long) ((-Math.log(1 - Math.random()) / lowestRate) * 1000000000.);
387 } else {
388 return (long) (1000000000. / lowestRate + 0.5);
389 }
390 }
391
392 @Override
393 public void uncaughtException(Thread t, Throwable e) {

Callers 1

Calls 1

randomMethod · 0.80

Tested by

no test coverage detected