Skip to content

Nextjs 15.1 not saving Static Content on Redis on build time using instrumentation using @neshca/cache-handler #74958

Open
@joanaavelar

Description

@joanaavelar

Link to the code that reproduces this issue

https://codesandbox.io/p/devbox/priceless-hill-52c3m3

To Reproduce

  1. Update url from cache-handler with your Redis instance
  2. yarn install
  3. yarn build
  4. Verify that no key exists for /index in Redis
  5. yarn start
  6. Verify that no key exists for /index in Redis, but /xpto in Redis exists
  7. Go to the browser and open => http://localhost:3000/
  8. Verify that /index key exists in Redis

Current vs. Expected behavior

I was expecting to have /index and /xpto after yarn build. I don't have anything being saved.
I was expecting to have /index also after yarn start. I only have /xpto being saved.

Provide environment information

Operating System:
  Platform: win32
  Arch: x64
  Version: Windows 10 Enterprise
  Available memory (MB): 32401
  Available CPU cores: 12
Binaries:
  Node: 22.4.1
  npm: 10.9.0
  Yarn: 1.22.22
  pnpm: N/A
Relevant Packages:
  next: 15.1.4 // Latest available version is detected (15.1.4).
  eslint-config-next: N/A
  react: 19.0.0
  react-dom: 19.0.0
  typescript: N/A
Next.js Config:
  output: standalone

Which area(s) are affected? (Select all that apply)

Instrumentation

Which stage(s) are affected? (Select all that apply)

next build (local), next start (local)

Additional context

I was expecting to use instrumentation implementation and have Redis cache being populated with pre-rendered pages on build time, but it's only happening on start time. Besides that, I am unable to save the pre-rendered page if my page is on the root of the app, meaning app/page.tsx.
This issue happens both in 15.1 and 14.2.17 next versions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    InstrumentationRelated to Next.js Instrumentation.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions