Benchmarks
These benchmarks are non-scientific, and are measured in uncontrolled environments.
Their goal is to ensure that the performance of cavro
is adequate compared to other offerings,
and to highlight any performance regressions early.
Each test is run 3 times for each library under test, and the results collected. Graphs show the fastest run time.
Most Recent Run
- Commit Hash:
8335809da7257c46bc731db2d004a69bfe2e5a64
- Run time:
2023-10-17 14:33:31.823424512
complex_schema
Measure the time taken to decode and re-encode 1,000 values, randomly generated to match a 70 kb schema
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 2.4408 | 1 | 2.4408, 2.4587, 2.5137 |
avro_compat | 0.6821 | 0.2794 | 0.6832, 0.6934, 0.6821 |
cavro | 0.202 | 0.0827 | 0.2028, 0.2020, 0.2840 |
fastavro | 5.0318 | 2.0615 | 5.0947, 5.0318, 5.0344 |
fastavro_compat | 0.6819 | 0.2794 | 0.7351, 0.6819, 0.6821 |
many_numbers_decode
Given a large, single array of long
values encoded in the avro binary format,
measure the time taken to decode them into python ints.
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.3649 | 1 | 0.3661, 0.3670, 0.3649 |
avro_compat | 0.1347 | 0.369 | 0.1347, 0.1349, 0.1358 |
cavro | 0.0098 | 0.0269 | 0.0098, 0.0102, 0.0116 |
fastavro | 0.1375 | 0.3768 | 0.1404, 0.1375, 0.1418 |
fastavro_compat | 0.135 | 0.3701 | 0.1354, 0.1355, 0.1350 |
many_numbers_encode
Given a large, single array of long
values,
measure the time taken to encode them in the avro binary format
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.7437 | 1 | 0.7437, 0.7513, 0.7451 |
avro_compat | 0.4503 | 0.6055 | 0.4562, 0.4503, 0.4520 |
cavro | 0.0317 | 0.0426 | 0.0323, 0.0317, 0.0324 |
fastavro | 0.0361 | 0.0486 | 0.0361, 0.0363, 0.0363 |
fastavro_compat | 0.4503 | 0.6055 | 0.4532, 0.4512, 0.4503 |
pypi_file
Measure the time taken to read all records from one file (11 Mb) of pypi download logs, sourced from google bigquery public dataset
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 5.8177 | 1 | 5.8177, 5.8736, 5.8367 |
avro_compat | 0.6076 | 0.1044 | 0.6076, 0.6107, 0.6079 |
cavro | 0.6352 | 0.1092 | 0.6352, 0.6451, 0.6423 |
fastavro | 1.9724 | 0.339 | 1.9728, 1.9724, 1.9908 |
fastavro_compat | 0.6043 | 0.1039 | 0.6043, 0.6086, 0.6106 |
schema_promotion
Measure the time taken to decode 1,000 values, randomly generated to match a 70 kb schema, using different reader/writer schemas.
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.8713 | 1 | 0.8804, 0.8713, 0.8735 |
avro_compat | 0.3368 | 0.3866 | 0.3370, 0.3368, 0.3370 |
cavro | 0.2554 | 0.2931 | 0.2577, 0.2625, 0.2554 |
fastavro | 40.3151 | 46.2678 | 40.3151, 40.7424, 40.7558 |
fastavro_compat | 0.3224 | 0.3701 | 0.3246, 0.3272, 0.3224 |
schema_promotion_container
Measure the time taken to decode 1,000 values from an object container, randomly generated to match a 70 kb schema, using different reader/writer schemas.
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.8876 | 1 | 0.8876, 0.8925, 0.8942 |
avro_compat | 0.0918 | 0.1034 | 0.0918, 0.0939, 0.1746 |
cavro | 0.2582 | 0.2909 | 0.3371, 0.2684, 0.2582 |
fastavro | 35.2819 | 39.7483 | 35.2819, 35.8722, 35.8195 |
fastavro_compat | 0.2516 | 0.2834 | 0.2525, 0.2516, 0.3471 |
simple_record_decode
Measure the time taken to decode 100,000 binary-encoded records using the simple schema, to each library's native record format
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.8803 | 1 | 0.8803, 0.8944, 0.8956 |
avro_compat | 0.4193 | 0.4764 | 0.4193, 0.4213, 0.4296 |
cavro | 0.1888 | 0.2145 | 0.1888, 0.1909, 0.1907 |
fastavro | 0.4063 | 0.4616 | 0.4137, 0.4086, 0.4063 |
fastavro_compat | 0.4065 | 0.4618 | 0.4129, 0.4065, 0.4075 |
simple_record_decode_dict
Measure the time taken to decode 100,000 binary-encoded records using the simple schema, to a dict
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 0.8713 | 1 | 0.8713, 0.8803, 0.8874 |
avro_compat | 0.4133 | 0.4744 | 0.4145, 0.4293, 0.4133 |
cavro | 0.2255 | 0.2588 | 0.2255, 0.2353, 0.2266 |
fastavro | 0.4118 | 0.4726 | 0.4153, 0.4166, 0.4118 |
fastavro_compat | 0.4014 | 0.4607 | 0.4014, 0.4125, 0.4175 |
simple_record_encode
Measure the time taken to encode 100,000 records using a simple (3 field) record schema. This takes advantage of cavro's class-based record types
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 1.3586 | 1 | 1.3586, 1.3849, 1.3648 |
avro_compat | 0.8141 | 0.5992 | 0.8223, 0.8421, 0.8141 |
cavro | 0.4439 | 0.3268 | 0.4439, 0.4501, 0.4469 |
fastavro | 0.3606 | 0.2655 | 0.3609, 0.3606, 0.3668 |
fastavro_compat | 0.8145 | 0.5995 | 0.8212, 0.8174, 0.8145 |
simple_record_encode_dict
Measure the time taken to encode 100,000 dicts using a simple (3 field) record schema.
History
Last Run Results
lib | min (s) | normalized (avro=1) | timings (s) |
---|---|---|---|
avro | 1.3591 | 1 | 1.3782, 1.3591, 1.3841 |
avro_compat | 0.8138 | 0.5988 | 0.8227, 0.8138, 0.8341 |
cavro | 0.2321 | 0.1707 | 0.2368, 0.2451, 0.2321 |
fastavro | 0.3596 | 0.2646 | 0.3596, 0.3705, 0.3632 |
fastavro_compat | 0.8164 | 0.6007 | 0.8164, 0.8261, 0.8458 |