How to speed up aggregation queries?
The aggregation don't use any Index.You need create a new Index:
{UserId:1,WorkflowStartTime:1}
If all is good, the agregation + explain must appear this line:
"winningPlan" :...
The aggregation don't use any Index.You need create a new Index:
{UserId:1,WorkflowStartTime:1}
If all is good, the agregation + explain must appear this line:
"winningPlan" :...