Queuing requests in functions when sleep
taketkt
HOBBYOP

a year ago

I have a question regarding functions, does it actually queue incoming requests when it's awakening from sleep?
Because I have a function that I send a fetch request to it from api, but if it was sleeping I will get this error:

request to http://function-bun.railway.internal:8080/api failed

it takes few seconds for it to completely awake, so the workaround I did was catching the error and recalling the fetch request again after 3 seconds.
But I'm trying to figure out if it should queue the incoming requests instead of the error I get, I mean is it a bug or just normal thing?

Solved

3 Replies

taketkt
HOBBYOP

a year ago

aa6099d5-117c-4b4b-8349-1798a4c3f481


brody
EMPLOYEE

a year ago

yes we hold the incoming request while we wake the container


brody
EMPLOYEE

10 months ago

!s


Status changed to Solved brody 11 months ago


Loading...