Skip to content

Commit 63b6533

Browse files
committed
add warning
1 parent fa3b420 commit 63b6533

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

.changeset/slimy-houses-punch.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,5 @@
33
---
44

55
fix: enable using the `direct` queue for isr
6+
7+
The `direct` mode is not recommended for use in production as it does not de-dupe requests.

packages/cloudflare/src/cli/build/utils/ensure-cf-config.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import logger from "@opennextjs/aws/logger";
12
import type { OpenNextConfig } from "@opennextjs/aws/types/open-next.js";
23

34
/**
@@ -22,6 +23,10 @@ export function ensureCloudflareConfig(config: OpenNextConfig) {
2223
mwUseFetchProxy: config.middleware?.override?.proxyExternalRequest === "fetch",
2324
};
2425

26+
if (config.default?.override?.queue === "direct") {
27+
logger.warn("The direct mode queue is not recommended for use in production.");
28+
}
29+
2530
if (Object.values(requirements).some((satisfied) => !satisfied)) {
2631
throw new Error(
2732
"The `open-next.config.ts` should have a default export like this:\n\n" +

0 commit comments

Comments
 (0)