hoangvvo / nextjs-mongodb-app

A Next.js and MongoDB web application, designed with simplicity for learning and real-world applicability in mind.
https://nextjs-mongodb.now.sh/
MIT License
1.53k stars 286 forks source link

Speed #110

Closed ghost closed 2 years ago

ghost commented 3 years ago

Hello, why posts opens so slow? It should work much faster

haggistech commented 3 years ago

slow all the time? Are you using this one or your own one?

hoangvvo commented 3 years ago

For future readers, the speed should depend on the database hosting. In this case, I'm using a free-tier database so it is obviously not so good.

In addition, in serverless, the database connection is not always persisted, so for some requests there is a short period of wait time for the connection to be established.