Prisma first query goes slow
Hi, I have a question. I've noticed that when Prisma executes its first query of the day, it's quite slow. Even a simple find operation for a single item from the database experiences this delay, sometimes taking more than ten seconds. I've read in the documentation that $connect can help with this when making the first query, but the question is where to place it. Additionally, the documentation also mentions that it's not necessary to use it explicitly so im a little confuse
Solution:Jump to solution
Yeah. they are talking about the same issue. well i will try this workaround that invokes a simple database query every 10-15 mins, in order to prevent Query Engine. thanks
4 Replies
Hi there, are you using MongoDB Atlas by any chance?
yes. im using MongoDB
Yup, I believe you're running into the same issue as here: https://discord.com/channels/937751382725886062/1157511403696046181
Maybe that thread could help?
Solution
Yeah. they are talking about the same issue. well i will try this workaround that invokes a simple database query every 10-15 mins, in order to prevent Query Engine. thanks