Skip to content

Fix tag cache stale logic and update tests#1193

Merged
vicb merged 14 commits intomainfrom
conico/fix-stale-cache
Apr 23, 2026
Merged

Fix tag cache stale logic and update tests#1193
vicb merged 14 commits intomainfrom
conico/fix-stale-cache

Conversation

@conico974
Copy link
Copy Markdown
Collaborator

Update the stale logic in the tag cache to consider the revalidatedAt timestamp, ensuring accurate cache validation.

It doesn't technically require the bump of aws

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 11, 2026

🦋 Changeset detected

Latest commit: 5d99b42

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@opennextjs/cloudflare Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Apr 11, 2026

Open in StackBlitz

npm i https://pkg.pr.new/@opennextjs/cloudflare@1193

commit: 5d99b42

Comment thread packages/cloudflare/src/api/overrides/incremental-cache/regional-cache.ts Outdated
Comment thread packages/cloudflare/src/api/overrides/tag-cache/d1-next-tag-cache.ts Outdated
Comment thread packages/cloudflare/src/api/overrides/tag-cache/d1-next-tag-cache.ts Outdated
Copy link
Copy Markdown
Contributor

@vicb vicb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@conico974 I have added a few minor comments, could you please take a look and let me know what you think.

Changes otherwise look good so I can update the PR when I get your feedback and get that merged.

Thanks!

@vicb vicb marked this pull request as ready for review April 20, 2026 08:43
Comment thread examples/e2e/app-router/open-next.config.ts Outdated
vicb
vicb previously requested changes Apr 22, 2026
Copy link
Copy Markdown
Contributor

@vicb vicb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The build is broken by my last commit (looks like nextVersion is undefined).
I'll take a look and fix

@vicb vicb dismissed their stale review April 23, 2026 08:00

fixed in the last commit

@vicb
Copy link
Copy Markdown
Contributor

vicb commented Apr 23, 2026

The build issue was related to globalThis.nextVersion not being defined at build time. The code has been updated to fix that.
The Open Next configuration is evaluated at build time

Copy link
Copy Markdown
Contributor

@vicb vicb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks a lot @conico974 !

@vicb vicb merged commit 1e8d232 into main Apr 23, 2026
7 checks passed
@vicb vicb deleted the conico/fix-stale-cache branch April 23, 2026 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants