Hi there,
We have a nextjs app deployed for which ~90% of the pages are static. As such, our main page uses getStaticPaths
and getStaticProps
with the hope that they would be created at build time and ready to render as soon as they’re deployed.
We are building thousands of these pages at build time and the deployment of the site reports to be successful. While the initial homepage request loads relatively quickly (a few seconds), most other initial page loads fail or, at best, are very slow (> 20 seconds). It does seem to “warm up” and, once it is, the pages are snappy.
After the site is deployed and the homepage has loaded we can see in the network tool prefetch queries executed for links on the page. They are a collection GET
requests for paths like $HOST/_next/data/$HASH/path/to/file.json
Most of these (often all) retrievals fail with net::ERR_ABORTED 502
at a duration of ~30 seconds (see screenshot attached).
Site details
- Example site id:
4dc4e81e-19c0-4973-85e3-62492d274e7d
- Site domain: https://debug-main-dulux.netlify.app/
I don’t see any errors or helpful diagnosis in the function logs for this site. Please could you provide some guidance on how we might get these pages to be ready to serve immediately after they’re deployed and avoid these errors?
Thanks very much, James