github opennextjs/opennextjs-aws v2.0.0

latest releases: v3.1.3, open-next@3.1.3, v3.1.2...
15 months ago

ISR done right — aka The Conico Release

We made some major improvements to the way ISR works. Staring from v2.0.0, the ISR cache is stored and shared across all server function instances via an S3 bucket. When the cache becomes stale, it's revalidated asynchronously while stale content continues to be served, leveraging AWS CloudFront's stale-while-revalidate (SWR) strategy.

In addition, we now support On-Demand Revalidation.

Read more about our revamped ISR approach.

Upgrading to v2

The open-next build now generates a revalidation-function bundle and a cache asset bundle in the .open-next directory. Here's what you need to do to upgrade:

  1. Create a revalidation Lambda function and connect it to an SQS FIFO queue
  2. Upload the cache files to an S3 bucket
  3. Update new environment variables and permissions for the server function
  4. Optionally, reuse the same bucket for both assets and cache

For an updated overview of the infrastructure with ISR revalidation, check out this architectural diagram.

Changes


🙏 🙏 A big thanks to @conico974, @dalhaan, @dkershner6, and @khuezy for their hard work on this release. And of course, a shout-out to everyone rallying for this feature here and on Discord.

Don't miss a new opennextjs-aws release

NewReleases is sending notifications on new releases.