These are chat archives for Automattic/mongoose

3rd
Apr 2019
Nqsty
@Nqsty
Apr 03 15:15
@StErMi Hey, can you provide a little bit of data?

I'm having an issue with a simple findById that takes more than 500ms with the following code:

const start = new Date().getTime();
Model.findById(<string of ObjectId>, err => {
  if (err) throw err;
  console.log(new Date().getTime() - start);
}).lean();

I'm lost on where I should look to fix this. :(

Nqsty
@Nqsty
Apr 03 19:33
Welp, some array had more than 8k elements, problem solved!