Quantcast
Channel: WP快站
Viewing all articles
Browse latest Browse all 233

How to overcome 10 sec serverless limitation timeout in Vercel?

$
0
0

Our React / Next.js web app has an animation rendering part. We does image rendering, generating GIF / MP4 with Vercel serverless solution.

But typically operation does not finish in 10sec. Sometimes it is 15 sec.

What can I do? I have two ideas.

  1. Run cron job in every 5 sec. It checks is it any rendering not yet executed, if so, then process it.

https://vercel.com/guides/what-can-i-do-about-vercel-serverless-functions-timing-out

Does cron job has same timeout? In Heroku not.

  1. Do rendering not on Vercel, but make a Node.js app, and run on Heroku, where same timeout is 15sec, and it can even increase to 45 sec.

What is your opionion?


Viewing all articles
Browse latest Browse all 233

Trending Articles