Skip to content

Instantly share code, notes, and snippets.

@jack-tjia
Last active October 4, 2017 13:34
Show Gist options
  • Save jack-tjia/b8a9b1908177411238269f6bd20f7a46 to your computer and use it in GitHub Desktop.
Save jack-tjia/b8a9b1908177411238269f6bd20f7a46 to your computer and use it in GitHub Desktop.
MongoDB Performance Tests

Test Machines

  • M1: Macbook Pro, 2.3G Intel Core i7 (8 cores), 16G 1600MHz DDR3 memory, SSD, OS X Seirra v10.12.5, with Percona Server for MongoDB v3.4.4-1.4
  • M2: Dell Inspiron 1520, Intel Core 2 Due CPU T7250 @ 2.0G x 2, 2G memory, Ubuntu 16.04 LTS, with Percona Server for MongoDB v3.4.4-1.4

Test Scripts

  • mongo-perf, is a micro benchmarking tool for the MongoDB server. It measures throughput of commands with regards to the number of threads. This tool is based on mongo benchRun command, which is designed as a QA baseline performance measurement tool; it is not designed to be a "benchmark".
  • mongoperf is a utility to check disk I/O performance independently of MongoDB.

Tests

  1. Test Query on M1 with mongo-perf
  2. Test I/O on M1 with mongoperf - SSD
  3. Test I/O on M1 with mongoperf - Memory
  4. Test Query on M2 with mongo-perf

Test I/O on M1 with mongoperf - Cached

Command to Test

echo "{nThreads:16,fileSizeMB:10000,r:true,w:true}" | mongoperf

It tests I/O performance with memory cache by reading/writing 5G file with 1 ~ 32 threads.

Test Result 1

mongoperf
use -h for help
parsed options:
{ nThreads: 32, fileSizeMB: 5000, mmf: true, r: true, w: true }
creating test file size:5000MB ...
1GB...
2GB...
3GB...
4GB...
testing...
options:{ nThreads: 32, fileSizeMB: 5000, mmf: true, r: true, w: true }
wthr 32
read:1 write:1
new thread, total running : 1
8570 ops/sec
8626 ops/sec
8407 ops/sec
8979 ops/sec
8840 ops/sec
8857 ops/sec
8691 ops/sec
9206 ops/sec
read:1 write:1
new thread, total running : 2
17010 ops/sec
17373 ops/sec
17437 ops/sec
18319 ops/sec
18662 ops/sec
20416 ops/sec
21187 ops/sec
22865 ops/sec
new thread, total running : 4
read:read:1 write:11 write:
1
44625 ops/sec
48159 ops/sec
55819 ops/sec
67969 ops/sec
84124 ops/sec
109995 ops/sec
149102 ops/sec
229491 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 8
read:1 write:1
830198 ops/sec
5005395 ops/sec
20839520 ops/sec
21824576 ops/sec
21488652 ops/sec
21801395 ops/sec
21795502 ops/sec
21739187 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 16
23553132 ops/sec
21791592 ops/sec
21935369 ops/sec
21895612 ops/sec
21937935 ops/sec
21886364 ops/sec
21788194 ops/sec
21877613 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 32
25262141 ops/sec
21823770 ops/sec
21903977 ops/sec
21703112 ops/sec
21768098 ops/sec
21614145 ops/sec
21652065 ops/sec
21834802 ops/sec
21656512 ops/sec
21831090 ops/sec
21687108 ops/sec
21823050 ops/sec
21809084 ops/sec
21526276 ops/sec
21748402 ops/sec
21879160 ops/sec
21782437 ops/sec
21885632 ops/sec
21790154 ops/sec
21859601 ops/sec
21807976 ops/sec
21871567 ops/sec
21828487 ops/sec
^C

Test Result 2

mongoperf
use -h for help
parsed options:
{ nThreads: 32, fileSizeMB: 5000, mmf: true, r: true, w: true }
creating test file size:5000MB ...
1GB...
2GB...
3GB...
4GB...
testing...
options:{ nThreads: 32, fileSizeMB: 5000, mmf: true, r: true, w: true }
wthr 32
read:1 write:1
new thread, total running : 1
34614 ops/sec
39158 ops/sec
39680 ops/sec
38118 ops/sec
40597 ops/sec
43122 ops/sec
45883 ops/sec
46181 ops/sec
new thread, total running : 2
read:1 write:1
96415 ops/sec
109109 ops/sec
111462 ops/sec
121141 ops/sec
130249 ops/sec
140562 ops/sec
133746 ops/sec
133220 ops/sec
read:1 write:1
read:1 write:1
new thread, total running : 4
263429 ops/sec
408314 ops/sec
745374 ops/sec
2167992 ops/sec
11800384 ops/sec
16031392 ops/sec
17460194 ops/sec
16206824 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 8
22567191 ops/sec
22660667 ops/sec
21562897 ops/sec
22433915 ops/sec
21141028 ops/sec
21525614 ops/sec
21209213 ops/sec
21143922 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 16
22272521 ops/sec
19910223 ops/sec
20708392 ops/sec
21391294 ops/sec
21623895 ops/sec
21662825 ops/sec
21397572 ops/sec
22186859 ops/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 32
25537662 ops/sec
22246400 ops/sec
22260581 ops/sec
22299225 ops/sec
22156834 ops/sec
22180030 ops/sec
22239969 ops/sec
22338912 ops/sec
21669866 ops/sec
21715296 ops/sec
21758185 ops/sec
^C

Conclusion:

  • The best performance is about 21M ops/sec.
  • In test result 1, during 8 threads stage, the I/O performance increased significantly from 0.83M to 21M. In test result 2, it is during 4 threads stage. This should be cache warming up.
  • The max CPU load could reach 100% during test.

Test I/O on M1 with mongoperf - SSD

Command to Test

echo "{nThreads:16,fileSizeMB:10000,r:true,w:true}" | mongoperf

It tests I/O performance of the SSD without caching by reading/writing 10G file with 1 ~ 16 threads.

Test Result

mongoperf
use -h for help
parsed options:
{ nThreads: 32, fileSizeMB: 10000, r: true, w: true }
creating test file size:10000MB ...
1GB...
2GB...
3GB...
4GB...
5GB...
6GB...
7GB...
8GB...
9GB...
testing...
options:{ nThreads: 32, fileSizeMB: 10000, r: true, w: true }
wthr 32
new thread, total running : 1
read:1 write:1
10122 ops/sec 39 MB/sec
9234 ops/sec 36 MB/sec
10281 ops/sec 40 MB/sec
10566 ops/sec 41 MB/sec
10253 ops/sec 40 MB/sec
9401 ops/sec 36 MB/sec
10657 ops/sec 41 MB/sec
10062 ops/sec 39 MB/sec
new thread, total running : 2
read:1 write:1
18442 ops/sec 72 MB/sec
19131 ops/sec 74 MB/sec
17996 ops/sec 70 MB/sec
18286 ops/sec 71 MB/sec
17930 ops/sec 70 MB/sec
18007 ops/sec 70 MB/sec
18663 ops/sec 72 MB/sec
19486 ops/sec 76 MB/sec
read:1 write:1
read:new thread, total running : 4
1 write:1
27761 ops/sec 108 MB/sec
16528 ops/sec 64 MB/sec
24288 ops/sec 94 MB/sec
15766 ops/sec 61 MB/sec
25736 ops/sec 100 MB/sec
26322 ops/sec 102 MB/sec
25295 ops/sec 98 MB/sec
26537 ops/sec 103 MB/sec
read:1 write:1
read:read:1 write:1
1 write:1
read:1 write:1
new thread, total running : 8
31706 ops/sec 123 MB/sec
31105 ops/sec 121 MB/sec
28373 ops/sec 110 MB/sec
18202 ops/sec 71 MB/sec
27010 ops/sec 105 MB/sec
21697 ops/sec 84 MB/sec
32799 ops/sec 128 MB/sec
33312 ops/sec 130 MB/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : read:161
 write:1
40874 ops/sec 159 MB/sec
41449 ops/sec 161 MB/sec
36565 ops/sec 142 MB/sec
23223 ops/sec 90 MB/sec
28315 ops/sec 110 MB/sec
34973 ops/sec 136 MB/sec
38977 ops/sec 152 MB/sec
40010 ops/sec 156 MB/sec
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:1 write:1
read:read:1 write:1 write:11

read:1 write:1
read:1 write:1
read:1 write:1
new thread, total running : 32
51801 ops/sec 202 MB/sec
41748 ops/sec 163 MB/sec
35626 ops/sec 139 MB/sec
33821 ops/sec 132 MB/sec
53418 ops/sec 208 MB/sec
52824 ops/sec 206 MB/sec
53735 ops/sec 209 MB/sec
36152 ops/sec 141 MB/sec
34746 ops/sec 135 MB/sec
38720 ops/sec 151 MB/sec
53112 ops/sec 207 MB/sec
53269 ops/sec 208 MB/sec
52715 ops/sec 205 MB/sec
30983 ops/sec 121 MB/sec
34575 ops/sec 135 MB/sec
43115 ops/sec 168 MB/sec
52570 ops/sec 205 MB/sec
51408 ops/sec 200 MB/sec
49504 ops/sec 193 MB/sec
29090 ops/sec 113 MB/sec
35363 ops/sec 138 MB/sec
40673 ops/sec 158 MB/sec
52995 ops/sec 207 MB/sec
53218 ops/sec 207 MB/sec
47779 ops/sec 186 MB/sec
30566 ops/sec 119 MB/sec
34904 ops/sec 136 MB/sec
^C

Conclusion:

  • The best performance is about 50K ops/sec, 150MB/sec.
  • The max CPU load is around 30% ~ 40% during test.

Test Query on M1 with mongo-perf

Command to Test

python benchrun.py -f testcases/simple_query.js -t 1 2 4 8 16.

It tests simple queries with 1, 2, 4, 8, 16 threads. Test on Percona Server for MongoDB v3.4.4-1.4 with default wiredTiger storage engine.

Test Result

Percona Server for MongoDB shell version v3.4.4-1.4
connecting to: mongodb://localhost:27017/
Percona Server for MongoDB server version: v3.4.4-1.4
db version: 3.4.4-1.4
3ee0bb263c7a6747ac2cea4e54fa67eabc11faff

load('util/utils.js')

load('testcases/simple_query.js')

mongoPerfRunTests([1, 2, 4, 8, 16], 1, 1, 5, 1, "%", [], 0, {"writeCmdMode": "true", "safeGLE": "false", "readCmdMode": "false", "writeConcern": {"j": "false"}}, false, false);

Queries.Empty
1	12174.392529941651
2	24104.844979876645
4	29032.076227515176
8	45661.71821072411
16	39168.538608552015
Queries.IdentityView.Empty
1	12264.643630468772
2	25329.44309851845
4	28120.559344892372
8	38851.543352484536
16	38614.32130572879
Aggregation.Empty
1	4153.565358525166
2	9215.930245203717
4	11857.011864403394
8	17189.580413782907
16	13151.820771206954
Queries.NoMatch
1	9895.891328915392
2	20163.23628958708
4	25273.2712805825
8	38666.308684104675
16	34203.52066856931
Queries.IdentityView.NoMatch
1	12187.042523745047
2	24458.865334797574
4	26317.48244036036
8	38170.5070781574
16	37019.54153946675
Aggregation.NoMatch
1	7210.712304255031
2	14168.702543413156
4	17970.18195046582
8	23811.80567202562
16	18059.909984777983
Queries.IntIdFindOne
1	15396.886894413326
2	29701.439405108216
4	35050.84988192727
8	57621.23190963996
16	47887.02101157471
Queries.IdentityView.IntIdFindOne
1	0
2	0
4	0
8	0
16	0
Aggregation.IntIdFindOne
1	9500.46821053271
2	18698.714675774194
4	23167.709486441745
8	25814.498797625612
16	19293.138580115767
Queries.IntNonIdFindOne
1	14974.244467402208
2	29890.36733788229
4	34223.07616218598
8	55835.3864768058
16	47496.371552975324
Queries.IdentityView.IntNonIdFindOne
1	0
2	0
4	0
8	0
16	0
Aggregation.IntNonIdFindOne
1	9580.655157591691
2	18690.197006562088
4	22376.544443041596
8	25557.624807542594
16	19200.735414348557
Queries.IntIDRange
1	6231.321828739413
2	12354.801099697248
4	16631.14939379683
8	23299.57541442385
16	21106.095618674335
Queries.IdentityView.IntIDRange
1	11491.267740120653
2	23335.508355443395
4	25901.374053491778
8	37678.08774297765
16	36409.84111031595
Aggregation.IntIDRange
1	3303.6792408893466
2	6257.263894580348
4	9551.842259403113
8	14635.741468260429
16	12090.535841677018
Queries.IntNonIDRange
1	9793.807425107943
2	19940.394560918787
4	24022.018586070313
8	40492.67515542086
16	34231.96616661346
Queries.IdentityView.IntNonIDRange
1	11544.917256029268
2	23098.831683492946
4	26009.092414643994
8	38616.97781302849
16	38357.17521937478
Aggregation.IntNonIDRange
1	6922.115513876291
2	13596.83642754288
4	17794.035166871905
8	24956.68676672178
16	18142.03877702909
Queries.RegexPrefixFindOne
1	11943.583262909377
2	24175.793011386195
4	26491.225863362306
8	41667.38134680841
16	39046.70410524276
Queries.IdentityView.RegexPrefixFindOne
1	11808.221000859714
2	22782.172254005458
4	24220.804880280422
8	34898.639467057204
16	37576.59326549316
Aggregation.RegexPrefixFindOne
1	8201.909647040382
2	16068.83355116187
4	18550.261310524857
8	24896.933188431605
16	18629.30934717805
Queries.TwoInts
1	8310.163515804596
2	15234.511433430758
4	18604.374144464804
8	27475.721638486746
16	26507.351233022255
Queries.IdentityView.TwoInts
1	11140.14735181355
2	22853.705337882497
4	25817.71067981144
8	37969.98042844203
16	38781.8012865677
Aggregation.TwoInts
1	5941.704954832925
2	10715.724345422832
4	13593.158097101752
8	17126.428042161107
16	15706.781222702197
Queries.StringRangeWithNonSimpleCollation
1	7601.482550996928
2	15886.05779274457
4	20385.482342296094
8	34043.56305580232
16	28649.22887244476
Queries.IdentityView.StringRangeWithNonSimpleCollation
1	11580.23955807114
2	23123.256094627075
4	25930.8377759818
8	37848.530358120755
16	36965.99557759156
Aggregation.StringRangeWithNonSimpleCollation
1	5250.014637215855
2	10412.505882574027
4	14324.218006674586
8	20592.80464259905
16	15877.839746979418
Queries.StringRangeWithSimpleCollation
1	8652.733471257787
2	17551.205833807137
4	22158.772491543812
8	34323.526744570205
16	29803.362609706594
Queries.IdentityView.StringRangeWithSimpleCollation
1	11492.403682045831
2	22362.126103756622
4	25541.843003740403
8	37923.19839310748
16	36733.918572631716
Aggregation.StringRangeWithSimpleCollation
1	5997.763159630989
2	10425.663109230512
4	15353.979196635388
8	22399.092504813776
16	16436.904028325167
Queries.StringUnindexedInPredWithNonSimpleCollation
1	4470.7431425913555
2	10197.818941398964
4	13347.912439867678
8	19994.973486941653
16	18072.275943041153
Aggregation.StringUnindexedInPredWithNonSimpleCollation
1	4497.461632654529
2	9241.742887295195
4	12748.468557320854
8	17221.56030273028
16	14198.888997741562
Queries.StringUnindexedInPredWithSimpleCollation
1	5852.3376987637275
2	12100.256008093094
4	15135.087385148792
8	22331.824087940047
16	20145.593490588777
Aggregation.StringUnindexedInPredWithSimpleCollation
1	5483.146696416611
2	11027.676824489585
4	14629.507336939576
8	19393.046684538283
16	15348.85707261157
Queries.IntNonIdFindOneProjectionCovered
1	9978.035018114368
2	20417.62107174467
4	25265.81318486141
8	40100.101019377355
16	34685.01457428155
Queries.IdentityView.IntNonIdFindOneProjectionCovered
1	10096.539083454487
2	18378.497036513087
4	20182.057276796826
8	19393.59940897828
16	18627.714658758257
Aggregation.IntNonIdFindOneProjectionCovered
1	6215.029339920264
2	12317.522717135997
4	15923.299525928804
8	23576.957566670204
16	17046.652999916787
Queries.IntNonIdFindOneProjection
1	10114.730225552486
2	20309.519490410024
4	25185.401836667377
8	40908.26636022992
16	34712.1789973576
Queries.IdentityView.IntNonIdFindOneProjection
1	10052.056614116902
2	17263.51921726352
4	20668.173671025437
8	19621.0791953152
16	19163.903518364492
Aggregation.IntNonIdFindOneProjection
1	6254.528355301355
2	12311.175137271743
4	16252.700992175112
8	23800.938261078547
16	17353.55754113187
Queries.IntNonIdFindProjectionCovered
1	5458.36621274913
2	11192.176004733778
4	15067.132798093584
8	22051.77851710248
16	20642.53809388836
Queries.IdentityView.IntNonIdFindProjectionCovered
1	11512.854724954588
2	22824.077569981066
4	25337.50196091362
8	37616.86424333648
16	37399.17997552494
Aggregation.IntNonIdFindProjectionCovered
1	1983.7615234968862
2	4679.545477258872
4	7026.027808038747
8	10113.429007743374
16	8398.37132653562
Queries.FindProjection
1	7702.096564105998
2	15442.238546819819
4	20481.650601588663
8	30334.080635965063
16	27239.875463920816
Queries.IdentityView.FindProjection
1	12109.13124246576
2	23912.006118520567
4	26758.790356216574
8	38148.13505264426
16	37780.918434649444
Aggregation.FindProjection
1	2399.3535130750784
2	6105.581137624245
4	8324.797001873829
8	11857.470024466687
16	9467.536114865457
Queries.FindWideDocProjection
1	3868.1873673996365
2	8990.330836818779
4	13602.436612817235
8	20744.35473028383
16	18999.315413642315
Queries.IdentityView.FindWideDocProjection
1	11940.238237029193
2	24120.918849880363
4	27142.01564366684
8	38046.80344888544
16	38368.294883104325
Aggregation.FindWideDocProjection
1	1989.5821078624745
2	4782.5203288589755
4	7447.904143984685
8	10294.442861032006
16	8666.59990895951
Queries.FindProjectionThreeFieldsCovered
1	8848.428723145624
2	17816.307566908843
4	22541.020432042882
8	37486.919695368466
16	31535.293218736922
Queries.IdentityView.FindProjectionThreeFieldsCovered
1	11059.046409097968
2	22707.96677081857
4	25520.704239991686
8	38720.656111494834
16	37779.628843200306
Aggregation.FindProjectionThreeFieldsCovered
1	5157.678249084391
2	10810.423969003641
4	13966.6027057832
8	20585.388564706747
16	15644.106306115813
Queries.FindProjectionThreeFields
1	7088.440966846234
2	14426.998368678629
4	19186.005515959107
8	28885.84618885188
16	26421.48439720485
Queries.IdentityView.FindProjectionThreeFields
1	11832.334476968392
2	22735.109262009944
4	26327.82524203173
8	38338.1197413323
16	38123.474689186
Aggregation.FindProjectionThreeFields
1	2182.9828463074555
2	4779.90660081293
4	7468.4936040007815
8	10590.133908486412
16	8883.097149340801
Queries.FindProjectionDottedField
1	6360.049325769196
2	13058.318739963937
4	16998.726953503035
8	24727.017117843934
16	22436.007408051668
Queries.IdentityView.FindProjectionDottedField
1	12086.018360471286
2	24466.22176572915
4	26707.335232843197
8	37827.59235153715
16	38056.50715647296
Aggregation.FindProjectionDottedField
1	1560.9186881649316
2	3677.251834477889
4	5469.655663130292
8	7395.871315792942
16	5979.472505796946
Queries.FindProjectionDottedField.Indexed
1	9427.67412553973
2	19583.79781495052
4	24582.16159815021
8	41948.042296840205
16	34717.7829670138
Queries.IdentityView.FindProjectionDottedField.Indexed
1	10927.417041292882
2	22496.934025995623
4	24147.671924802064
8	37251.520370345956
16	37889.84547355727
Aggregation.FindProjectionDottedField.Indexed
1	5257.701495775717
2	11235.530649442011
4	14726.435814001175
8	21574.743758968838
16	16549.083505655202
Queries.LargeDocs
1	2.136512671365311
2	3.5853802534784167
4	5.121812243509246
8	5.114132085757858
16	5.240344297170755
Queries.IdentityView.LargeDocs
1	12182.02378743578
2	24960.635760699806
4	27625.61877181638
8	36987.620459288766
16	37897.69801890825
Aggregation.LargeDocs
1	1.4349742323470815
2	2.3502618779297486
4	3.1096197988801566
8	3.39713618331441
16	2.954830066799474

Conclusion:

  • The best ops-per-second is around 45K.
  • CPU usage during the test could reach to 80% - 90%. Max mongo server connections is 34 based on result of mongostat.

Test Query on M1 with mongo-perf

Command to Test

python benchrun.py -f testcases/simple_query.js -t 1 2 4 --host 192.168.0.22.

It tests simple queries with 1, 2, 4 threads. Test on Percona Server for MongoDB v3.4.4-1.4 with inMemory storage engine.

Test Result

Percona Server for MongoDB shell version v3.4.4-1.4
connecting to: mongodb://192.168.0.22:27017/
Percona Server for MongoDB server version: v3.4.5-1.5
db version: 3.4.5-1.5
868e35ca968c21e80767d20371ce96b57355b8a3

load('util/utils.js')

load('testcases/simple_query.js')

mongoPerfRunTests([1, 2, 4], 1, 1, 5, 1, "%", [], 0, {"writeCmdMode": "true", "safeGLE": "false", "readCmdMode": "false", "writeConcern": {"j": "false"}}, false, false);

Queries.Empty
1	129.3602179001004
2	178.25955268816006
4	169.78447096384096
Queries.IdentityView.Empty
1	192.1779583843017
2	287.637863929313
4	381.78795799376996
Aggregation.Empty
1	101.37917587910015
2	140.60790080780734
4	149.38204368161695
Queries.NoMatch
1	205.94767291114925
2	309.88855784889057
4	460.25967162173777
Queries.IdentityView.NoMatch
1	199.45171741105682
2	294.57113573825967
4	401.9558003753444
Aggregation.NoMatch
1	179.75452721763162
2	317.7355052373502
4	413.6572685064281
Queries.IntIdFindOne
1	206.93107237833712
2	332.3549431168633
4	276.83870527978644
Queries.IdentityView.IntIdFindOne
1	0
2	0
4	0
Aggregation.IntIdFindOne
1	178.78929153796463
2	277.0459645165907
4	398.7213035677192
Queries.IntNonIdFindOne
1	209.04473537389984
2	198.659951947007
4	134.23342123782797
Queries.IdentityView.IntNonIdFindOne
1	0
2	0
4	0
Aggregation.IntNonIdFindOne
1	164.8292331230131
2	280.4467468874494
4	350.58245490184987
Queries.IntIDRange
1	149.18295479318869
2	241.08777848480022
4	268.7499937743237
Queries.IdentityView.IntIDRange
1	155.59051293338646
2	293.4614515855391
4	371.29284807110974
Aggregation.IntIDRange
1	130.12203815679547
2	203.9145609960927
4	265.0747323680527
Queries.IntNonIDRange
1	211.10949791589118
2	373.97411556319025
4	291.23470992923495
Queries.IdentityView.IntNonIDRange
1	171.41062362736807
2	331.5321813620667
4	400.4598932265864
Aggregation.IntNonIDRange
1	59.614824432348236
2	286.64520584397167
4	379.13868143460337
Queries.RegexPrefixFindOne
1	205.73544935535563
2	219.1516180229174
4	225.8126630139864
Queries.IdentityView.RegexPrefixFindOne
1	174.28009146410847
2	274.8391901538162
4	109.14549949602745
Aggregation.RegexPrefixFindOne
1	95.09300175314016
2	286.47204497013456
4	216.37977009798175
Queries.TwoInts
1	198.73962796420057
2	322.71369909680055
4	302.29916497388854
Queries.IdentityView.TwoInts
1	134.4194477977181
2	293.61335110970685
4	60.81447376753195
Aggregation.TwoInts
1	74.89347958879141
2	147.49180667154604
4	28.733541185053333
Queries.StringRangeWithNonSimpleCollation
1	148.72652167194963
2	276.82989539813116
4	306.8572808962844
Queries.IdentityView.StringRangeWithNonSimpleCollation
1	180.49796296580692
2	290.2261410175907
4	138.36747785426533
Aggregation.StringRangeWithNonSimpleCollation
1	134.23521285270203
2	27.511894504177125
4	310.31609563319836
Queries.StringRangeWithSimpleCollation
1	186.06389418155044
2	181.11944742034024
4	393.01604502966376
Queries.IdentityView.StringRangeWithSimpleCollation
1	195.0026625747377
2	253.9549037534854
4	317.5130832488686
Aggregation.StringRangeWithSimpleCollation
1	164.4063950292136
2	99.46482343797871
4	446.56957448356053
Queries.StringUnindexedInPredWithNonSimpleCollation
1	113.73533786877935
2	194.5821931149436
4	350.7392052309225
Aggregation.StringUnindexedInPredWithNonSimpleCollation
1	96.39668012228609
2	261.2665724777405
4	338.10994945276167
Queries.StringUnindexedInPredWithSimpleCollation
1	212.46782779802058
2	21.959701159838215
4	344.174738051971
Aggregation.StringUnindexedInPredWithSimpleCollation
1	67.45708541883167
2	210.4400169228847
4	324.31112273602247
Queries.IntNonIdFindOneProjectionCovered
1	224.05634967315305
2	85.05328430755786
4	412.2940842763333
Queries.IdentityView.IntNonIdFindOneProjectionCovered
1	178.97539876397235
2	115.58223955335833
4	272.51368531526913
Aggregation.IntNonIdFindOneProjectionCovered
1	48.82858237870133
2	207.72663254974563
4	93.8513955495216
Queries.IntNonIdFindOneProjection
1	169.7007933652416
2	55.95944530641625
4	127.71561988638632
Queries.IdentityView.IntNonIdFindOneProjection
1	10.898614548302957
2	343.93164139181397
4	88.24642844890343
Aggregation.IntNonIdFindOneProjection
1	75.12669622297138
2	270.599945041251
4	374.8452794822169
Queries.IntNonIdFindProjectionCovered
1	91.81471789927926
2	131.26397663023891
4	202.9260629070795
Queries.IdentityView.IntNonIdFindProjectionCovered
1	170.7632197195369
2	190.63614085052322
4	365.8050169650291
Aggregation.IntNonIdFindProjectionCovered
1	101.87086236669491
2	136.9304854146473
4	161.19977856959073
Queries.FindProjection
1	79.93482421415197
2	81.44652217361605
4	57.80049454182581
Queries.IdentityView.FindProjection
1	9.003010381596347
2	92.46125893177754
4	353.9797623973095
Aggregation.FindProjection
1	84.21350078117003
2	106.73154036270836
4	117.65313049274515
Queries.FindWideDocProjection
1	86.33245571972458
2	97.24935599315364
4	40.095169736876926
Queries.IdentityView.FindWideDocProjection
1	152.27756747862077
2	65.52837284688528
4	418.39261923542136
Aggregation.FindWideDocProjection
1	76.21140725161516
2	91.68788647886097
4	101.4288190575242
Queries.FindProjectionThreeFieldsCovered
1	172.28657626046694
2	352.7507173728531
4	423.40904053020773
Queries.IdentityView.FindProjectionThreeFieldsCovered
1	175.31339765750948
2	259.8535447074733
4	231.22762967203684
Aggregation.FindProjectionThreeFieldsCovered
1	124.17774599252702
2	200.06137340937258
4	103.90419531983889
Queries.FindProjectionThreeFields
1	69.06630145364603
2	105.9365065963397
4	116.66375007291485
Queries.IdentityView.FindProjectionThreeFields
1	171.7481128628179
2	271.20067537716574
4	380.4922613651146
Aggregation.FindProjectionThreeFields
1	81.3806790699066
2	91.2334260107895
4	96.64039413372923
Queries.FindProjectionDottedField
1	93.95556520157159
2	130.64418799619952
4	132.17847297008115
Queries.IdentityView.FindProjectionDottedField
1	130.05785426412055
2	233.1355772747217
4	346.051833308146
Aggregation.FindProjectionDottedField
1	77.64757780476924
2	88.09598560192322
4	79.92543350130231
Queries.FindProjectionDottedField.Indexed
1	151.1562756211884
2	102.11061316196367
4	294.5402957846637
Queries.IdentityView.FindProjectionDottedField.Indexed
1	115.8097742289418
2	147.79088527139172
4	175.39887417011383
Aggregation.FindProjectionDottedField.Indexed
1	68.2355956687214
2	232.99328262443635
4	344.59604678618376

Conclusion:

  • The best ops-per-second is around 300.
  • CPU usage during the test could reach to 10% - 15%. Max mongo server connections is 11 based on result of mongostat.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment