Next.js Discord

Discord Forum

Next ISR Randomly Stops Working

Unanswered
Asian paper wasp posted this in #help-forum
Open in Discord
Asian paper waspOP
We keep coming across instances where the ISR just randomly stops. No idea why this keeps happening.

In our current iteration, this is happening on a dev instance. We do have some Railway API logs showing an Axios 500 error to our NextJS App. Then on Vercel, we can only look at the past 24 hours of logs for the web app. 🤦‍♂️ So, that's super useful. Seems like I'm going to have to send logs to a DB now. Any other ideas on how to resolve this? I've already verified that the ENV variables are identical. Seems like a thing that can't be fixed without more logs.

16 Replies

Asian paper waspOP
Our API Logs:
[Nest] 15  - 08/20/2025, 3:54:06 AM   ERROR [Logger-NextJSService-revalidatePortal]: Failed to revalidate access: Request failed with status code 500
[Nest] 15  - 08/20/2025, 3:54:06 AM   ERROR AxiosError: Request failed with status code 500
    at settle (/app/node_modules/axios/dist/node/axios.cjs:2026:12)
    at IncomingMessage.handleStreamEnd (/app/node_modules/axios/dist/node/axios.cjs:3142:11)
    at IncomingMessage.emit (node:events:530:35)
    at endReadableNT (node:internal/streams/readable:1698:12)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
    at Axios.request (/app/node_modules/axios/dist/node/axios.cjs:4252:41)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async NextJSService.revalidatePortal (/app/dist/nextjs/nextjs.service.js:28:30)
    at async AccessService.createOne (/app/dist/access/access.service.js:125:17)
    at async VerificationService.verifyEmailResponse (/app/dist/verification/verification.service.js:102:17)
[Nest] 15  - 08/20/2025, 3:54:06 AM   ERROR [Logger-AccessService-createOne]: Error during account update: Revalidation failed.
[Nest] 15  - 08/20/2025, 3:54:06 AM   ERROR InternalServerErrorException: Revalidation failed.
    at NextJSService.revalidatePortal (/app/dist/nextjs/nextjs.service.js:33:19)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async AccessService.createOne (/app/dist/access/access.service.js:125:17)
American Sable
can you send NextJSService.revalidatePortal @Asian paper wasp
@American Sable can you send NextJSService.revalidatePortal <@920874494619443223>
Asian paper waspOP
No. I don't have it connected to an endpoint in Nest and it's not documented in Postman. Which are both now new issues on the API repo.
you should probably go to their server for help if its related to them then
Asian paper waspOP
The API is NestJS. The Web App is NextJS.

The logs above are Nest, but we can only get 24 hours of logs from Next deployed on Vercel. This happened a couple of days ago, and I'm not getting to researching it.
Asian paper waspOP
As I mentioned before, I'm unable to do anything now because of the lack of Vercel logs. So, I'm looking at adding a MongoDB into the mix to send the logs to.

As of now, I'm just trying to figure out if there is anything else I can do for this last situation. All signs point to not being able to fix it this time.
American Sable
Asian paper waspOP
Since I hit this road block, I went ahead and redeployed the app. So, I'll have to wait until the next time it errors out in order to provide more.

If I add sentry now, will that allow me to retrieve older logs from today? Or is this a moving forward type of thing?
American Sable
moving forward type of thing
it wont give u the past
also sentry keeps the stack trace and other information so i assume it will also be easier to debug