R
Railway•8mo ago
Faith

Larvel API wakes up from nap with a error but when hit again with another request it works

Hey guys im currently using Laravel 10. And i am trying to use the "sleep" feature but when my app is sleeping, and if i do a get request it will take some time to spin up (expected) but then it wil throw a NGINX problem shown on the screenshot below. any idea?
No description
Solution:
try implementing a readiness health check
Jump to solution
10 Replies
Percy
Percy•8mo ago
Project ID: N/A
Faith
FaithOP•8mo ago
N/A
Brody
Brody•8mo ago
are you using a health check?
Faith
FaithOP•8mo ago
yea but just on /
Solution
Brody
Brody•8mo ago
try implementing a readiness health check
Faith
FaithOP•8mo ago
should i just remove it imma try that
Brody
Brody•8mo ago
you are doing the exact opposite of what i said, you always want to have a health check, preferably not / though
Faith
FaithOP•8mo ago
aight bet thanks
Brody
Brody•8mo ago
a proper readiness health check is going to be best, not just return 200, check if you are connected to the database and such
Faith
FaithOP•8mo ago
bet thank you, i will cook it up now 💯
Want results from more Discord servers?
Add your server