forked from oluies/akka-sample-trading
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME
50 lines (31 loc) · 2.24 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
Trading Sample with Scala and Akka.
Including performance benchmark test described in blog: http://blog.jayway.com/2010/08/10/yet-another-akka-benchmark/
=== Latest Results ===
https://github.com/patriknw/akka-sample-trading/wiki/Results
=== How to run benchmark from distribution ===
Download and unzip distribution assembly from https://github.com/patriknw/akka-sample-trading/downloads
The zip contains all jar files, including necessary dependencies.
In the scripts directory of the distribution there is a run_benchmark.sh script that can be used to launch tests.
Argument to the script is the junit test class or classes to run.
./run_benchmark.sh org.samples.trading.akka.AkkaPerformanceTest
There is also a script for running all benchmark tests.
./run_all_benchmarks.sh
You need to define JAVA_HOME for JDK6, if you don't have it as default.
Benchmark options can be defined with variable:
export BENCH_PROPS='-Dbenchmark.useTxLogFile=false -Dbenchmark=true -Dbenchmark.minClients=1 -Dbenchmark.maxClients=40 -Dbenchmark.useDummyOrderbook=false'
Better accuracy (running tests longer) is achieved if you define jvm parameter:
-Dbenchmark=true
By default the benchmark is run without transaction logging, you can use transaction logging by defining jvm parameter:
-Dbenchmark.useTxLogFile=true
By default the benchmark is run with 1 to 40 client threads, you can define another range with jvm parameters:
-Dbenchmark.minClients=2 -Dbenchmark.maxClients=6
To push the message passing to the limits, the order matching logic can be turned off with jvm parameter:
-Dbenchmark.useDummyOrderbook=true
To control how long the tests are running you can define repeatFactor, default is 150 when benchmark=true:
-Dbenchmark.repeatFactor=300
To control the length of the warmup period you can define warmupRepeatFactor, default is 200 when benchmark=true:
-Dbenchmark.warmupRepeatFactor=300
To avoid timeouts when running the benchmarks under circumstances where execution is slowed (e.g., when using an invasive profiler) you can define timeDilation, default is 1 (higher values increase the timeout):
-Dbenchmark.timeDilation=1
Results, including charts are by default stored in directory 'target/benchmark', but can be specified with jvm parameter
-Dbenchmark.resultDir=results