public class JLBH extends Object implements NanoSampler
Constructor and Description |
---|
JLBH(JLBHOptions jlbhOptions) |
JLBH(JLBHOptions jlbhOptions,
PrintStream printStream,
Consumer<JLBHResult> resultConsumer)
Use this constructor if you want to test the latencies in more automated fashion.
|
Modifier and Type | Method and Description |
---|---|
NanoSampler |
addProbe(String name)
Add a probe to measure a section of the benchmark.
|
net.openhft.chronicle.core.jlbh.JLBH.JLBHEventHandler |
eventLoopHandler()
Call this instead of start if you want to install JLBH as a handler on your event loop thread
|
void |
sample(long nanoTime) |
void |
sampleNanos(long nanos) |
void |
start()
Start benchmark
|
public JLBH(@NotNull JLBHOptions jlbhOptions)
jlbhOptions
- Options to run the benchmarkpublic JLBH(@NotNull JLBHOptions jlbhOptions, @NotNull PrintStream printStream, Consumer<JLBHResult> resultConsumer)
jlbhOptions
- Options to run the benchmarkprintStream
- Used to print text output. Use System.out to show the result on you standard out (e.g. screen)resultConsumer
- If provided, accepts the result data to be retrieved after the latencies have been measuredpublic NanoSampler addProbe(String name)
name
- Name of probepublic void start()
public net.openhft.chronicle.core.jlbh.JLBH.JLBHEventHandler eventLoopHandler()
public void sampleNanos(long nanos)
sampleNanos
in interface NanoSampler
public void sample(long nanoTime)
Copyright © 2018. All rights reserved.