[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [ooni-probe/master] Add parallelism command line option
commit d484bf69ed62bbeda38b9d29f27da5ac55125e79
Author: aagbsn <aagbsn@xxxxxxxx>
Date: Sun Dec 23 23:23:14 2012 +0000
Add parallelism command line option
Aka router-melt-mode
---
ooni/oonicli.py | 4 +++-
ooni/runner.py | 1 +
2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/ooni/oonicli.py b/ooni/oonicli.py
index b06bde9..c333b27 100644
--- a/ooni/oonicli.py
+++ b/ooni/oonicli.py
@@ -36,7 +36,9 @@ class Options(usage.Options):
["collector", "c", None,
"Address of the collector of test results. (example: http://127.0.0.1:8888)"],
["logfile", "l", None, "log file name"],
- ["pcapfile", "p", None, "pcap file name"]]
+ ["pcapfile", "O", None, "pcap file name"],
+ ["parallelism", "p", "10", "input parallelism"],
+ ]
compData = usage.Completions(
extraActions=[usage.CompleteFiles(
diff --git a/ooni/runner.py b/ooni/runner.py
index 319f0b0..7787992 100644
--- a/ooni/runner.py
+++ b/ooni/runner.py
@@ -420,6 +420,7 @@ def runTestCases(test_cases, options, cmd_line_options):
try:
input_unit_factory = InputUnitFactory(test_inputs)
+ input_unit_factory.inputUnitSize = int(cmd_line_options['parallelism'])
except Exception, e:
log.exception(e)
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits