next.js
e5e0d356 - Use StageController for runtime prerendering (#89972)

Commit
5 days ago
Use StageController for runtime prerendering (#89972) Stacked on #89971 This controller was introduced to help with dev time validation. It models stage transitions in a helpful way that will become more useful soon as we get more advanced with what kinds of sync IO are considered errors. To prepare for this we will update the implementation to use the stage controller for build and runtime prerendering not just dev We don't yet use it for static prerendering because that one is so simple and there is really no stage beyond the first one and then an abort so we will keep it as is Additionally, the private cache store no longer has the `runtimeStagePromise`. when you first enter this store type during a runtime prerender we wait until the outer store's runtime stage has begun. Previously the proimse signifying this stage transition was included in the private cache store itself so nested caches could similarly wait, however you can't actually get to a nested cache until after it is resolved b/c the outermost one blocks.
Author
Parents
Loading