Appearance
Benchmark (0.0.2)
Synthetic publish throughput benchmarks using cometmq-bench against a local single-node broker.
Environment
- Broker:
cometmq-broker0.0.2 (release build) - Tool:
cometmq-bench(publisher mode) - Concurrency: 10 workers
- Payload pattern: zeros
- Compression: lz4 (threshold 1024 bytes)
- Publisher confirms: disabled unless stated
- Persistence: as noted per test
Throughput (Non-Persistent, No Confirms)
| Payload (bytes) | Msg/s | Approx MB/s* |
|---|---|---|
| 64 | 99,902 | 6.37 |
| 128 | 102,593 | 12.57 |
| 512 | 69,481 | 35.96 |
| 1,024 | 26,222 | 25.79 |
| 16,384 | 24,601 | 384.05 |
| 131,072 | 3,120 | 392.93 |
| 1,048,576 | 3,015 | 3,014.97 |
| 8,388,608 | 1,332 | 11,162.88 |
Throughput (Persistent, No Confirms)
| Payload (bytes) | Msg/s | Approx MB/s* |
|---|---|---|
| 64 | 68,900 | 4.41 |
| 128 | 66,615 | 8.17 |
| 512 | 47,349 | 24.48 |
| 1,024 | 26,445 | 26.03 |
| 16,384 | 24,789 | 386.98 |
| 131,072 | 2,973 | 374.60 |
| 1,048,576 | 2,714 | 2,713.60 |
| 8,388,608 | 1,228 | 10,301.44 |
Throughput (Persistent + Confirms)
| Payload (bytes) | Msg/s | Approx MB/s* |
|---|---|---|
| 64 | 34,470 | 2.21 |
| 128 | 33,337 | 4.09 |
| 512 | 27,678 | 14.33 |
| 1,024 | 17,910 | 17.63 |
| 16,384 | 17,669 | 275.67 |
| 131,072 | 2,969 | 374.10 |
| 1,048,576 | 2,930 | 2,929.69 |
| 8,388,608 | 1,299 | 10,896.38 |
*Approx MB/s = (Msg/s * PayloadBytes) / 1_000_000.
Summary (Msg/s)
| Mode | 64B | 128B | 1KB | 16KB | 1MB |
|---|---|---|---|---|---|
| Non-persistent | 99,902 | 102,593 | 26,222 | 24,601 | 3,015 |
| Persistent | 68,900 | 66,615 | 26,445 | 24,789 | 2,930 |
| Persistent + confirms | 34,470 | 33,337 | 17,910 | 17,669 | 2,414 |
Notes
- lz4 compression activates above 1024 bytes.
- Numbers reflect loopback network (no external latency).
- Persistence + confirms show expected throughput reduction due to fsync and acknowledgment round-trips.
Tool Invocation (Example)
bash
cometmq-bench pub \
--count 50000 \
--payload-bytes 128 \
--concurrency 10 \
--persistent false \
--confirm false
Adjust parameters for different payload sizes and durability/confirm modes.