|
| 1 | +#!/usr/bin/env python3 |
| 2 | + |
1 | 3 | """ This script is responsible using vegeta to make a list of performance tests (configured via command line) and saves its result on csv file |
2 | 4 | """ |
3 | 5 |
|
@@ -55,8 +57,16 @@ def __init__(self, argv): |
55 | 57 | self.repetitions = int(argv[5]) |
56 | 58 | self.test_sequence = argv[6] |
57 | 59 | else: |
58 | | - print("usage: "+argv[0]+ " <vegetaPatternTarFile> [daemonOnCore - or 0-1 or 0-2 ...]") |
59 | | - print(" [turboGethAddress i.e localhost:porta or 1.1.1.1:porta] [gethHomeDir i.e ../../../turbo-geth/] [test repetitions i.e 10] [test seq i.e 200:30,400:10]") |
| 60 | + print("Usage: " + argv[0] + " vegetaPatternTarFile [daemonOnCore] [turboGethAddress] [turboGethHomeDir] [testRepetitions] [testSequence]") |
| 61 | + print("") |
| 62 | + print("Launch an automated performance test sequence on Silkrpc and RPCDaemon using Vegeta") |
| 63 | + print("") |
| 64 | + print("vegetaPatternTarFile path to the request file for Vegeta attack") |
| 65 | + print("daemonOnCore logical cpu list in taskset format (e.g. - or 0-1 or 0-2 or 0,2...) [default: " + DEFAULT_DAEMON_ON_CORE +"]") |
| 66 | + print("turboGethAddress address of TG Core component as <address>:<port> (e.g. localhost:9090) [default: " + DEFAULT_TG_ADDRESS + "]") |
| 67 | + print("turboGethHomeDir path to TG home folder (e.g. ../../../turbo-geth/) [default: " + DEFAULT_GETH_HOME_DIR + "]") |
| 68 | + print("testRepetitions number of repetitions for each element in test sequence (e.g. 10) [default: " + str(DEFAULT_REPETITIONS) + "]") |
| 69 | + print("testSequence list of query-per-sec and duration tests as <qps1>:<t1>,... (e.g. 200:30,400:10) [default: " + DEFAULT_TEST_SEQUENCE + "]") |
60 | 70 | sys.exit(-1) |
61 | 71 |
|
62 | 72 |
|
@@ -221,9 +231,6 @@ def close(self): |
221 | 231 | # |
222 | 232 | # main |
223 | 233 | # |
224 | | -# usage: ptrhon perf.py <vegetaPatternTarFile> [daemonOnCore - or 0-1 or 0-2 ...] |
225 | | -# [turboGethAddress i.e localhost:porta or 1.1.1.1:porta] [gethHomeDir i.e ../../../turbo-geth/] [test repetitions i.e 10] [test seq i.e 200:30,400:10] |
226 | | -# |
227 | 234 | def main(argv): |
228 | 235 | """ Executes tests on selected user configuration |
229 | 236 | """ |
@@ -269,7 +276,7 @@ def main(argv): |
269 | 276 |
|
270 | 277 |
|
271 | 278 | # |
272 | | -# main |
| 279 | +# module as main |
273 | 280 | # |
274 | 281 | if __name__ == "__main__": |
275 | 282 | main(sys.argv) |
|
0 commit comments