Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How many transactions per second can happen in MongoDB?

I am writing a feature that might lead to us executing a few 100s or even 1000 mongodb transactions for a particular endpoint. I want to know if there is a maximum limit to the number of transactions that can occur in mongodb?

I read this old answer about SQL server Can SQL server 2008 handle 300 transactions a second? but couldn't find anything on mongo

like image 767
nickMason Avatar asked Nov 01 '25 02:11

nickMason


2 Answers

It's really hard to find a non-biased benchmark, let alone the benchmark that your objectively reflect your projected workload.

Here is one, by makers of Cassandra (obviously, here Cassandra wins): Cassandra vs. MongoDB vs. Couchbase vs. HBase

enter image description here

few thousand operations/second as a starting point and it only goes up as the cluster size grows.

Once again - numbers here is just a baseline and can not be used to correctly estimate the performance of your application on your data. Not all the transactions are created equal.

like image 101
Anton Avatar answered Nov 03 '25 15:11

Anton


Well, this isn't a direct answer to your question, but since you have quoted a comparison, I would like to share an experience with Couchbase. When it comes to Couchbase: a cluster's performance is usually limited by the network bandwidth (assuming you have given it SSD/NVMe storage which improves the storage latency). I have achieved in excess of 400k TPS on a 4 node cluster running Couchbase 4.x and 5.x. in a K/V use case.

Node specs below:

12 core x 2 Xeon on HP BL460c blades

SAS SSD's (NVMe would generally be a lot better)

10 GBPS network within the blade chassis

Before we arrived here, we moved on from MongoDB that was limiting the system throughput to a few tens of thousand at most.

like image 44
SolutionGuy Avatar answered Nov 03 '25 17:11

SolutionGuy