Hi @Weide_Zhang,
I imported the document and I tried to test this via mongosh
but got the below results from the execution stats output for both an M0 and serverless instance.
Serverless instance:
executionStats: {
executionSuccess: true,
nReturned: 1,
executionTimeMillis: 0,
totalKeysExamined: 0,
totalDocsExamined: 1,
executionStages: {
stage: 'COLLSCAN',
nReturned: 1,
executionTimeMillisEstimate: 0,
works: 2,
advanced: 1,
needTime: 0,
needYield: 0,
saveState: 0,
restoreState: 0,
isEOF: 1,
direction: 'forward',
docsExamined: 1
}
},
command: { find: 'collection', filter: {}, '$db': 'db' },
serverInfo: {
host: 'serverlessinstance0-lb.redacted.mongodb.net',
port: 27017,
version: '6.2.0',
gitVersion: '290112ef1396982a187217b4cb8a943416ad0db1'
}
M0 instance:
executionStats: {
executionSuccess: true,
nReturned: 1,
executionTimeMillis: 4,
totalKeysExamined: 0,
totalDocsExamined: 1,
executionStages: {
stage: 'COLLSCAN',
nReturned: 1,
executionTimeMillisEstimate: 4,
works: 3,
advanced: 1,
needTime: 1,
needYield: 0,
saveState: 0,
restoreState: 0,
isEOF: 1,
direction: 'forward',
docsExamined: 1
}
},
command: { find: 'collection', filter: {}, '$db': 'db' },
serverInfo: {
host: 'ac-iceu1mh-shard-00-01.redacted.mongodb.net',
port: 27017,
version: '5.0.15',
gitVersion: '935639beed3d0c19c2551c93854b831107c0b118'
}
The executionTimeMillis
for both are <5ms.
Can you advise how you got these times? Was this from the execution stats output?
Regards,
Jason