Changelog
@ogygia/postrender
Every release of @ogygia/postrender, newest first.
- Latest
- 0.16.0
- Versions
- 8
0.16.0 minor
Dependency updates only @ogygia/postrender
0.15.1 patch
Dependency updates only @ogygia/postrender
0.15.0 minor
Dependency updates only @ogygia/postrender
0.14.0 minor
Minor Changes
- Breaking:
postrender()requiresdataShake(). Addimport { dataShake } from '@ogygia/data-shake/vite'and listdataShake()besidepostrender(). Without it the build fails withplugin_needs_plugin, because every deferred region would look the page up and render the stored page again. @ogygia/postrender: Breaking: a page rendered for a request that carries a cookie or anauthorizationheader is not stored (it is still served a stored copy, and its own render is stampedprivate, no-store); a route whose pages are the same with them opts in withconfig = { postrender: 'with-credentials' }.@ogygia/core: a render's per-visitor reads also count a function inlocals,inand the keys oflocals, the request headers read whole or copied while one is personal,headers.has()and a requestclone(), client address, forwarded host, location and session headers,getClientAddress(), per-requestplatformdata, and an own-originfetchthat carries the visitor's cookies.
Patch Changes
- Durations are measured on the monotonic clock: the memory store's TTLs, a federation deploy check's retry wait, the profiler's recording window, deadlines and busy waits, the testing API's wait, and the perf CLI's waits. A wall-clock step no longer moves them.
- -
@ogygia/compiler: new package, ogygia's compiler and its Vite plugin:@ogygia/compiler(the compiler),@ogygia/compiler/vite(ogygia(),definePlugin) and@ogygia/compiler/ids. It uses core only through@ogygia/core/contract; core never depends on it. -@ogygia/core: breaking: the@ogygia/core/vite,@ogygia/core/internal/compilerand@ogygia/core/internal/compiler-idsimport paths are gone. Import fromogygia/vite(or@ogygia/compiler/vite),@ogygia/compilerand@ogygia/compiler/idsinstead; the names are the same. -@ogygia/core: the types of theogygia:*virtual modules and the build's switches are named in core (@ogygia/core/contract), so core's own types no longer reach into the compiler. -ogygia:ogygia/vite,ogygia/internal/compilerandogygia/internal/compiler-idsre-export@ogygia/compiler; apps change nothing. -@ogygia/barrels,@ogygia/cli,@ogygia/content,@ogygia/devtools,@ogygia/federation,@ogygia/flags,@ogygia/postrender,@ogygia/router: they takedefinePluginand the compiler from@ogygia/compiler, a new peer dependency (ogygiabrings it). - A deploy now counts as a write for the app's own stored pages: on the first request after a boot with a new build, the pages the previous build stored are dropped (origin and edges) before any is served, so a new release never serves the old release's HTML.
- The head's end is found as the browser reads it: an
app.htmlthat writes</HEAD>gets ogygia's head injections, and a</head>inside a head script's text (a JSON-LD string) no longer takes them into the script. The body's end is found in any case. - A cached hole (
maxAge) that reads a flag, or a cookie, header orlocalsvalue, for an anonymous visitor is no longer kept and served to other visitors. - Stitching finds stitch holes as a browser reads the page: a hole inside a comment, or a region whose class merely says "stitch", is no longer stitched, and an upper-case or single-quoted
stitchattribute is. - A page whose store step fails after postrender read it (a stitched hole whose
endpointis not a URL, say) now goes out as rendered,no-storeand unstored, and the failure is said once per page (postrender_capture_failed). The visitor got a response whose body was already read. - In dev, the
would-storeheader and the "stays per-request" note now give the verdict production gives: a page the app marksno-storeorprivateis no longer shown aswould-store, and a permanent redirect is. - A stored page answers
If-None-Matchwith the weak comparison RFC 9110 asks for: aW/etag a compressing CDN made, and*, now revalidate with a 304 (before, only the exact strong etag did, so such revalidations sent the whole page). - A remote function call (a
queryorquery.live) made from a stored page is no longer answered with the stored page's HTML, and is never stored as the page: postrender stores and serves page requests only. - A stored page's stitch holes are found as the browser reads the page: a region tag inside a fallback's comment, script, style, title or textarea text no longer shifts which part of the page a hole covers, so an edge (ESI) rewrite never wraps half a region.
- A stored page is served only to the build that stored it, recorded in the new optional
buildfield of the publicPostrenderEntrytype (a custom store keeps it as part of the entry): another build's page is a miss, so a rolling deploy's old instances can no longer hand the new release their pages, and pages stored before this release are rendered again once.
Dependencies: @ogygia/core@0.14.0, @ogygia/compiler@0.14.0, @ogygia/machine@0.14.0
0.13.0 minor
Minor Changes
- Postrender's stores and edges are classes:
new MemoryStore(),new ValkeyStore(client),new UpstashStore({ url, token }),new CloudflareKvStore(binding),new AkamaiEdge(cfg),new CloudFrontEdge(cfg)andnew CloudflareEdge(cfg)replacememoryStore(),valkey(),upstash(),cloudflareKv(),akamai(),cloudfront()/awsCloudfront()andcloudflare()(same arguments).
Patch Changes
- Every ogygia error and warning has a code and a page at
ogygiajs.dev/e/<code>: dev prints the wording and the link, a production build prints the link alone ([ogygia] https://ogygiajs.dev/e/<code>?<args>), so the wording stays out of the client and server bundles. - A render that a publish (or any invalidation) lands during is served but not stored, so the page as it was before the publish is no longer kept (#194).
- A stampede flight settles however the request that opened it ends, so a plugin answering that request no longer leaves every later cold request for the page waiting (#194).
- Requests waiting on a page render that a publish overtook are let go at once and share one new render, which is stored, instead of waiting for the old render to end and then each rendering the page alone.
- A response refused after its body was read is sent rebuilt from that body, not as the spent original.
- A page whose render was stored just after a publish evicted it is no longer served while it is taken back out, and that evict is now tried again when the store fails it (#332).
- A store that is down now prints
postrender_store_failedonce per failing streak, instead of every render quietly missing and nothing being kept. - A store outage is said once (
postrender_store_failed) even while calls overlap: a slow store call that started before the outage and answers after it no longer ends the failing streak (#364). - A successful form post's response now waits for its page's stored copy to be evicted (an outbox send, tried again within 2 s), so the redirect's GET right after renders fresh instead of getting the page from before the post (#283).
- A peer whose store fails to apply a thaw notice now answers an error, so the sender sends it again, instead of answering done and deduping the retry;
app.notifyrejects once every hook ran when one failed (#287).
Dependencies: @ogygia/core@0.13.0, @ogygia/machine@0.13.0
0.12.0 minor
Dependency updates only @ogygia/postrender
0.11.0 minor
Patch Changes
- The deploy-thaw build marker no longer lapses after a day: it is stored apart from the page TTL and rewritten every boot.
- A stored page older than the policy
ttlis a miss on read, so a store without its own expiry still ages pages out. - A store that fails during invalidation is reported as a store failure, and the edges still purge (a throwing
evictByTagstopped the whole invalidation and was blamed on the edge).
Dependencies: @ogygia/core@0.11.0