Understand progress information and statistical reports

This document introduces in detail the progress information during the operation of MatrixBench and the statistical report printed out after the operation is completed.

Notes!
Currently, mxbench is open source, and your review and contribution are welcome. Please [click here] (https://github.com/ymatrix-data/mxbench/blob/master/README.md) read README.

1 Progress information

Example:

● Stdin Writer Report
  ● period start: 2022-04-29 10:08:11, end: 2022-04-29 10:08:16, period: 5.000129734s

  ● count written in total: 637025 rows/ 1500000 rows 42%, 637025 rows in this period

  ● size written in total: 160878718 bytes/ 360000003 bytes 44%, 160878718 bytes in this period

  ● size written to MxGate in total: 350075440 bytes, 350075440 bytes in this period

● Telematics Benchmark Report
  ● stats for query SINGLE_TAG_LATEST_QUERY with parallel 8: progress: 100%

  ● stats for query MULTI_TAG_LATEST_QUERY with parallel 8: progress: 43%

The progress information consists of two parts: Writer and Benchamrk.

1.1 Writer

  • period start, period end, period: the start and end time and time period of the statistics window;
  • count written: The number of data rows written and the estimated number of data rows, and the percentage of both. xx in this period: the number of rows written in this statistics window;
  • size written: The number of data bytes and the estimated data bytes that have been written, and the percentage of both. xx in this period: the number of bytes written in this statistics window;
  • size written to MxGate: The number of bytes written to MatrixGate after converting data into text. xx in this period: The number of bytes written to MatrixGate in this statistics window.

1.2 Benchmark

The execution progress of a query statement under a concurrency parallel parameter. When a query statement is performed simultaneously with data loading, the query statement will continue until the data loading is completed, so it may run multiple rounds in a loop. This progress report only displays the progress report for the most recent round.

2 Statistical Report

2.1 Writer

┌───────────────────────────────────────────────────────┐
│            Summary Report for Stdin Writer            │
├─────────────────────────────────┬─────────────────────┤
│ start time:                     │ 2022-04-27 13:29:01 │
├─────────────────────────────────┼─────────────────────┤
│ stop time:                      │ 2022-04-27 13:29:58 │
├─────────────────────────────────┼─────────────────────┤
│ size written to MxGate (bytes): │ 848333400           │
├─────────────────────────────────┼─────────────────────┤
│ lines inserted:                 │ 1500000             │
├─────────────────────────────────┼─────────────────────┤
│ compress ratio:                 │ 1.561276 : 1        │
└─────────────────────────────────┴─────────────────────┘
  • start time: data load start time;
  • end time: data load termination time;
  • size written to MxGate (bytes): The number of bytes to write data to MatrixGate;
  • lines inserted: The number of inserts of data. Because UPSERT may exist, this number may be higher than the actual number of data in the database.
  • compress ratio: compression ratio, that is, the ratio of the size of the data written to MatrixGate to the size of the table in the actual database.

2.2 Benchmark

For each query statement, a related report will be printed in real time under each parallel parameter.

┌─────────────────┬───────────────┐
│ Overall Latency │ 29.948370582s │
│ Average Latency │   13.723304ms │
│ P75 Latency     │    14.35972ms │
│ P50 Latency     │   13.654556ms │
│ P25 Latency     │   12.925912ms │
│ TPS             │           582 │
└─────────────────┴───────────────┘
  • Pxx represents the delay of the xx percentile. For example, P75 is 14.35972ms, which means that 25% of the number of times the query is executed have a delay higher than it and 75% lower than it. P50 is the median.
  • TPS: The number of times a query statement is executed per second.

Summary report:

┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│                                                Summary Report for Telematics Benchmark                                                │
├─────────────────────┬─────────────────────────────────────┬─────────────────────────────────────┬─────────────────────────────────────┤
│ Parallel\Query Name │ SINGLE_TAG_LATEST_QUERY             │ MULTI_TAG_LATEST_QUERY              │ SINGLE_TAG_DETAIL_QUERY             │
├─────────────────────┼─────────────────────────────────────┼─────────────────────────────────────┼─────────────────────────────────────┤
│ 8                   │ ┌─────────────────┬───────────────┐ │ ┌─────────────────┬───────────────┐ │ ┌─────────────────┬───────────────┐ │
│                     │ │ Overall Latency │ 30.008625133s │ │ │ Overall Latency │ 36.407016561s │ │ │ Overall Latency │ 29.948370582s │ │
│                     │ │ Average Latency │    23.81758ms │ │ │ Average Latency │  7.270212105s │ │ │ Average Latency │   13.723304ms │ │
│                     │ │ P75 Latency     │   24.911171ms │ │ │ P75 Latency     │  8.139682559s │ │ │ P75 Latency     │    14.35972ms │ │
│                     │ │ P50 Latency     │   23.411248ms │ │ │ P50 Latency     │  7.161237157s │ │ │ P50 Latency     │   13.654556ms │ │
│                     │ │ P25 Latency     │   20.899622ms │ │ │ P25 Latency     │  6.642459805s │ │ │ P25 Latency     │   12.925912ms │ │
│                     │ │ TPS             │           335 │ │ │ TPS             │             1 │ │ │ TPS             │           582 │ │
│                     │ └─────────────────┴───────────────┘ │ └─────────────────┴───────────────┘ │ └─────────────────┴───────────────┘ │
│                     │ progress: 100%                      │ progress: 100%                      │ progress: 100%                      │
└─────────────────────┴─────────────────────────────────────┴─────────────────────────────────────┴─────────────────────────────────────┘
  • Each line represents the execution result of the query statement under a certain degree of concurrency.
  • Each column represents the execution result of each query statement under various concurrency degrees.
  • If the query statement set has been executed for multiple rounds (in the case of mixed load, the query statement will be executed continuously without ending the data load), only the results of the last round will be displayed.
  • If the query statement is executed incorrectly or the user interrupts the execution, the progress bar will display the current progress, and the statistics are based on the execution of the query statement.

Notes!
For MatrixBench to get started quickly, see MatrixBench to get started quickly; for MatrixBench complete command line parameter information, see MatrixBench command line parameters; for the main functions, see MatrixBench main functions.