Prismic Netlify communication issue (nextJs)

Hello

My site name is: www.scottlogic.com

I am having an issue with my app. It uses nextjs 12.3.1 and is hosted in netlify.
The issue is the following: it used to be so that whenever I make a change to a document in Prismic, the changes would be visible in the production version of the app within max 1 minute. Now it only notices the changes when I manually redeploy the site on netlify. Nobody has added any code to the repository of this app is in since April of this year.

Redeploying the site is a temporary solution but I don’t want to redeploy manually every time changes are made to prismic documents.

Crossposting this to Netlify forum as well.

Example: Sam Perridge | Scott Logic
on the above page, the title should be "Technical Advisor to the CEO" instead of " Head of Consultancy". In the Prismic document it's "Technical Advisor to the CEO".

In local preview it works fine but on develop preview and production it does not.

I have tried adding an access token to the prismic config but that has not solved the issue.

I am also aware of this forum thread. But many people reported still having the issue after updating to nextjs 14 and I'm trying to avoid that.

Thank you in advance.

Hi @balint1 ,

Welcome to the community :slight_smile:

My first suspicion would be the way the Next cache is configured in Netlify, so please let us know what they say.

Otherwise, please check that all your webhooks are firing correctly and make sure you aren't caching any refs.

Thanks.

Hi @Phil

Thank you for the welcome :smiley:

The cache headers are this:
cache-control: public,max-age=0,must-revalidate

The webhooks are firing correctly, no issues found in the logs.

No code has been added to the application's repository since April and I've been having this issue since late June.

Since this may be relevant here's what version of prismic and nextjs I'm using (copied from package.json):

"@prismicio/client": "^6.7.1",
"@prismicio/helpers": "^2.3.5",
"@prismicio/next": "^0.1.6",
"@prismicio/react": "^2.5.0",
"@prismicio/slice-simulator-react": "^0.2.2",
"next": "12.3.1"

Can it be that the outdated prismic/nextjs version is causing this issue?

Thanks.

It might be related, yes, are you following the revalidate steps recommended here?