Hi, what's the best way to log all queries with their execution time (how much milliseconds did the query take)?
mongoose.set('debug', true) shows only the query, not the time.
It seems that pre/post query middleware could be used, but in this case I need to add this callbacks to every Scheme I have, it requires a lot of code changes.
I would like to change only one place in project, like it works with mongoose.set('debug', true). Any ideas?