BonsaiDb Commerce Benchmark

small, writeheavy, 2 agent(s)

Configuration

Initial Data Set
Type Count
Products 100
Categories 10
Customers 100
Orders 125
Shopping Plans

This run executed 1000 shopping plans across 2 worker(s). All total, the workers will execute the following breakdown of operations:

Operation Invocations
Load 1
LookupProduct 2753
FindProduct 2883
CreateCart 988
AddProductToCart 5050
Checkout 894
RateProduct 4143

Summary

Backend Total Time Wall Time Transport
bonsaidb-local 6.702s 3.351s None
bonsaidb-local+lz4 7.741s 3.871s TCP
bonsaidb-quic 14.58s 7.288s UDP with TLS
bonsaidb-ws 11.68s 5.842s TCP
postgresql 49.77s 24.88s TCP
Table of Contents:

Operation Results

Load

Measures the time spent loading the initial data set and performing any pre-cache operations that most database administrators would perform on their databases periodically to ensure good performance.

This operation was executed 1 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 11.78ms 11.78ms 11.78ms 0s 0
bonsaidb-local+lz4 10.68ms 10.68ms 10.68ms 0s 0
bonsaidb-quic 14.47ms 14.47ms 14.47ms 0s 0
bonsaidb-ws 12.49ms 12.49ms 12.49ms 0s 0
postgresql 581.7ms 581.7ms 581.7ms 0s 0
LookupProduct

Meaures the time spent looking up a product by its id. This operation is meant to simulate the basic needs of the database to provide a product details page after a user clicked a direct link that contians the product's unique id, including the product's current rating.

This operation was executed 2753 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 135.3us 39.30us 1.120ms 87.46us 39
bonsaidb-local+lz4 157.1us 39.70us 4.663ms 181.1us 24
bonsaidb-quic 618.0us 336.9us 9.778ms 482.1us 28
bonsaidb-ws 437.2us 233.2us 8.648ms 338.9us 31
postgresql 1.700ms 421.2us 22.89ms 1.296ms 38
FindProduct

Measures the time spent looking up a product by its name (exact match, indexed). This operation is meant to simulate the basic needs of the database to provide a product details after finding a product by its name, including the product's current rating.

This operation was executed 2883 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 282.6us 66.30us 5.413ms 229.4us 35
bonsaidb-local+lz4 317.0us 72.90us 6.446ms 294.0us 31
bonsaidb-quic 721.3us 394.1us 7.443ms 378.6us 36
bonsaidb-ws 581.9us 276.7us 8.050ms 358.8us 48
postgresql 1.838ms 385.0us 50.43ms 1.591ms 26
CreateCart

Measures the time spent creating a shopping cart.

This operation was executed 988 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 218.1us 86.40us 1.360ms 110.3us 19
bonsaidb-local+lz4 259.1us 104.9us 5.019ms 256.5us 12
bonsaidb-quic 467.5us 249.8us 5.781ms 371.5us 13
bonsaidb-ws 394.5us 210.0us 7.922ms 380.1us 15
postgresql 2.294ms 969.2us 50.97ms 2.555ms 11
AddProductToCart

Measures the time spent adding a product to a shopping cart.

This operation was executed 5050 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 299.2us 118.3us 5.145ms 180.9us 63
bonsaidb-local+lz4 347.4us 130.9us 9.587ms 313.0us 50
bonsaidb-quic 796.8us 456.3us 12.19ms 625.4us 70
bonsaidb-ws 617.9us 342.6us 9.345ms 400.2us 91
postgresql 2.033ms 852.2us 27.40ms 1.382ms 103
Checkout

Measures the time spent converting a shopping cart into an order for a customer.

This operation was executed 894 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 492.3us 230.1us 5.234ms 263.2us 5
bonsaidb-local+lz4 606.5us 225.2us 9.688ms 582.5us 8
bonsaidb-quic 1.219ms 772.9us 11.09ms 795.2us 12
bonsaidb-ws 983.1us 552.7us 9.616ms 629.6us 16
postgresql 2.408ms 981.4us 13.11ms 1.285ms 14
RateProduct

Measures the time spent adding or updating a review of a product by a customer. Each customer can only have one review per product. When this operation is complete, all subsequent calls to LookupProduct and FindProduct should reflect the new rating. This simulates an 'upsert' (insert or update) operation using a unique index.

This operation was executed 4143 time(s) across each backend.

Backend Avg Min Max StdDev Outliers
bonsaidb-local 805.5us 418.5us 12.18ms 418.9us 39
bonsaidb-local+lz4 924.8us 293.0us 10.86ms 654.5us 56
bonsaidb-quic 1.257ms 726.6us 22.59ms 825.5us 55
bonsaidb-ws 1.062ms 586.6us 11.17ms 551.3us 60
postgresql 5.919ms 2.870ms 61.96ms 2.925ms 41