Skip to content

fix: enable using the direct queue for isr #319

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Feb 7, 2025
Merged

fix: enable using the direct queue for isr #319

merged 5 commits into from
Feb 7, 2025

Conversation

james-elicx
Copy link
Collaborator

@james-elicx james-elicx commented Feb 2, 2025

  • Allow use of direct for the queue.
  • Enable ISR tests for app router e2es.
  • Fix e2e isr route so it imports the manifest for the revalidation test.

Copy link

changeset-bot bot commented Feb 2, 2025

🦋 Changeset detected

Latest commit: 4fb97c3

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

Copy link

pkg-pr-new bot commented Feb 2, 2025

Open in Stackblitz

pnpm add https://pkg.pr.new/@opennextjs/cloudflare@319

commit: 4fb97c3

@james-elicx james-elicx marked this pull request as ready for review February 2, 2025 17:55
@james-elicx james-elicx force-pushed the james/isr branch 2 times, most recently from 28587f4 to b399584 Compare February 2, 2025 18:27
@vicb
Copy link
Contributor

vicb commented Feb 2, 2025

Awesome 🎉

I'll try to review the PR tomorrow afternoon!

This was referenced Feb 2, 2025
Copy link
Collaborator

@conico974 conico974 left a comment

Choose a reason for hiding this comment

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

While this will work and could be used right now to make ISR work, i think a better solution long term would be to use a queue system for deduplicating the revalidation.

With the direct queue, once a page is stale, every request for this page (while it is revalidating and available worldwide) will trigger a new revalidation.
KV will probably throw a lot of error because of the 1s write per key limitations

@james-elicx
Copy link
Collaborator Author

While this will work and could be used right now to make ISR work, i think a better solution long term would be to use a queue system for deduplicating the revalidation.

With the direct queue, once a page is stale, every request for this page (while it is revalidating and available worldwide) will trigger a new revalidation. KV will probably throw a lot of error because of the 1s write per key limitations

Agreed, I had wrote on the issue that we should do it as an additional piece of work separately to this - both should be available for people to use ideally.

Copy link
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.

Can you rebase and try to upstream the change?

@james-elicx
Copy link
Collaborator Author

Can you rebase and try to upstream the change?

I've opened opennextjs/opennextjs-aws#728 to upstream it.

@james-elicx james-elicx requested a review from vicb February 7, 2025 11:17
Copy link
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.

Thanks for the update 🚀

@james-elicx james-elicx merged commit a630aea into main Feb 7, 2025
7 checks passed
@james-elicx james-elicx deleted the james/isr branch February 7, 2025 11:30
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.

3 participants