Added help for columns

This commit is contained in:
Pünkösd Marcell 2020-10-23 16:17:24 +02:00
parent 94c1fdce92
commit 1063208d4d

View File

@ -13,6 +13,7 @@ import queue
import sys import sys
import csv import csv
import random import random
import textwrap
@dataclass(frozen=False, init=True) @dataclass(frozen=False, init=True)
@ -164,10 +165,22 @@ def write_results(results, file_handle):
def main(): def main():
parser = argparse.ArgumentParser( help_epilog = textwrap.dedent('''\
description='Birbnetes Benchmarker 3' CSV Columns meaning:
) id - Unique ID of a request (not sequential but at least unique)
http_start_time - Timestamp of when the HTTP request is started
http_complete_time - Timestamp of when the HTTP request is completed
status_code - Status code of the HTTP request
mqtt_arrive_time - Timestamp of when the corresponding MQTT message arrived
latency - Latency of the system (http_complete_time - mqtt_arrive_time) in milliseconds
rtt - Total round trip time (http_start_time - mqtt_arrive_time) in milliseconds
''')
parser = argparse.ArgumentParser(
description='Birbnetes Benchmarker 3',
epilog=help_epilog,
formatter_class=argparse.RawTextHelpFormatter
)
parser.add_argument('--workers', type=int, required=False, default=1, help='Number of workers (or threads)') parser.add_argument('--workers', type=int, required=False, default=1, help='Number of workers (or threads)')
parser.add_argument('--timeout', type=int, required=False, default=10, parser.add_argument('--timeout', type=int, required=False, default=10,
help='Maximum time for request sending (0 for unlimited)') help='Maximum time for request sending (0 for unlimited)')