Answer the question
In order to leave comments, you need to log in
How to see the execution time of mongoose aggregate (similar to Query.explain())?
model.collection.aggregate(...).explain is not a function
Answer the question
In order to leave comments, you need to log in
Option 1 - console.time:
console.time('aggregation time');
await model.collection.aggregate(...);
console.timeEnd('aggregation time');
model.aggregate(..., { explain: true })
model.aggregate(array).explain()
Mysterious padding of inline elements
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question