Status "in-queue"
Hi! I am running my serverless endpoint in sync mode. Sometimes I get response like
{'delayTime': 85437, 'id': 'sync-822bbbf3-bae5-4efa-bbfa-9658ffda0175-u1', 'status': 'IN_PROGRESS'}
or status in-queue.
1) why in sync mode it sends back in complete response?
2) how to get an actual completed response after I get the above response?9 Replies
1. Because sync is meant to wait until completion, unless its 60~ seconds after and your job hasn't completed
2. Use the /status to check, maybe every second if it returns in progress or complete
How am I supposed to check status every second? Isn't it like the request response cycle gets completed after it sends me back status in progress ?
No, thats the way it is
if you have the status button, click it many times to check
and if you're on program, use loop and hit that many times until its complete
try to Learn HTTP its gonna help you gain more insights about this, it returns that response you pasted, the connection is probably already closed so theres no more continuing until you try to hit another one
Sorry I got that wrong,it's /status endpoint and not the keyword
hmm okay okay glad you've got it!
you can use /status-sync instead of /status, it will do blocking call like runsync
Does it waits indefinitely while job is running unlike the /runsync which cancels out and returns the job id with IN_PROGRESS after like 60secs~
its same 60s, its due to cloudflare timeouts
Ahh ic