Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
fa74e70
refactor: remove createServerBundle.ts and integrate its functionalit…
conico974 Jun 27, 2026
33a6eff
feat: implement default overrides for bundle configurations and add t…
conico974 Jun 27, 2026
fe002e1
format
conico974 Jun 27, 2026
9ee9515
fix ts issue
conico974 Jun 27, 2026
6fad0c6
feat: add default overrides for AWS adapter and integrate Cloudflare …
conico974 Jun 27, 2026
84397ab
Revert "feat: add default overrides for AWS adapter and integrate Clo…
conico974 Jun 27, 2026
f22d37f
feat: enhance AWS adapter with default overrides and improve middlewa…
conico974 Jun 27, 2026
a3165f0
refactor(core): return ValidateConfigResult from validateConfig inste…
conico974 Jun 28, 2026
6296e94
refactor(core): extract buildOpenNextOutput, export OpenNextOutput type
conico974 Jun 28, 2026
4e82821
refactor(core): branch on ValidateConfigResult in compileOpenNextConfig
conico974 Jun 28, 2026
0af2e73
feat(core): overridable validateConfig and generic generateOutput on …
conico974 Jun 28, 2026
bab47f1
fix(core): use require.resolve for full-path overrides in resolve plugin
conico974 Jun 28, 2026
51b5e3b
format
conico974 Jun 28, 2026
a437de1
feat(core): enforce mandatory externals in serverBundle and update re…
conico974 Aug 1, 2026
cd8f83e
refactor(core): enhance resolve plugin to support dynamic override re…
conico974 Aug 1, 2026
c200d7a
feat(core): run the cache in a dedicated handler function
conico974 Aug 16, 2026
68fd48e
Merge remote-tracking branch 'origin/main' into vicb/review-pr-43
vicb Sep 17, 2026
c57027b
Merge remote-tracking branch 'origin/main' into vicb/review-pr-43
vicb Sep 18, 2026
c11ae26
fix(core): support streamed cache request bodies
vicb Sep 18, 2026
8df264e
fix(core): route cache operations through the cache transport
vicb Sep 18, 2026
f22f401
fix(aws): configure the dedicated cache Lambda
vicb Sep 18, 2026
269eb10
fix(core): separate the raw local cache handler
vicb Sep 18, 2026
3dccab9
fix(core): preserve legacy cache provider overrides
vicb Sep 18, 2026
653c963
fix(core): surface cache mutation failures
vicb Sep 18, 2026
f3db8a4
fix(core): preserve permanent cache revalidation
vicb Sep 18, 2026
5ec6856
test: keep cache integration imports lintable
vicb Sep 18, 2026
3395f73
fix(core): preserve cache request context storage
vicb Sep 18, 2026
9a31b2d
fix(core): validate cache revalidation tags
vicb Sep 18, 2026
76e2c64
fix(core): bundle middleware cache overrides
vicb Sep 18, 2026
53d1226
Revert "fix(aws): configure the dedicated cache Lambda"
vicb Sep 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions .changeset/cache-handler-function.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
"@opennextjs/core": minor
---

Add a dedicated cache handler function

The incremental cache, the tag cache and CDN invalidation can now run in their own function, bundled
to `.open-next/cache-function` and reachable over the new `cache` override.

The overrides for that function are configured through a new top level `cacheHandler` option:

```ts
export default {
default: {
override: {
cache: "local",
},
},
cacheHandler: {
incrementalCache: "s3",
tagCache: "dynamodb",
},
} satisfies OpenNextConfig;
```

Three `cache` implementations ship with core: `fetch` (HTTP), `local` (in-process, imports the cache
bundle) and `dummy`. Adapters that do not want the bundle can opt out with `skipCache` in
`buildAdapter`.

This is additive: the existing `default.override.incrementalCache` and `default.override.tagCache`
keep working unchanged.
8 changes: 8 additions & 0 deletions packages/core/src/adapters/cache-adapter.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { createGenericHandler } from "../core/createGenericHandler.js";

import { handler as cacheHandler } from "./cache-handler.js";

export const handler = await createGenericHandler({
handler: cacheHandler,
type: "cache",
});
Loading
Loading