Skip to content

Commit 01ee6ee

Browse files
anonrignevikashah
authored andcommitted
add compat_flag changelog for http servers (#24923)
1 parent b2cbc09 commit 01ee6ee

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
_build:
3+
publishResources: false
4+
render: never
5+
list: never
6+
7+
name: "Enable Node.js HTTP server modules"
8+
sort_date: "2025-09-01"
9+
enable_date: "2025-09-01"
10+
enable_flag: "enable_nodejs_http_server_modules"
11+
disable_flag: "disable_nodejs_http_server_modules"
12+
---
13+
14+
The `enable_nodejs_http_server_modules` flag enables the availability of Node.js
15+
HTTP server modules such as `node:_http_server` in Workers.
16+
17+
The `disable_nodejs_http_server_modules` flag disables the availability of these
18+
server modules.
19+
20+
This enables compatibility with Node.js libraries and existing code that
21+
use the standard Node.js HTTP server APIs. The available functionality includes:
22+
23+
* `http.createServer()` for creating HTTP servers
24+
* `http.Server` class for server instances
25+
* `http.ServerResponse` for handling server responses
26+
27+
This flag must be used in combination with the `enable_nodejs_http_modules` flag
28+
to enable full features of `node:http`.
29+
30+
This flag is automatically enabled for Workers using
31+
a compatibility date of 2025-09-01 or later when `nodejs_compat` is enabled.
32+
33+
See the [Node.js documentation](https://nodejs.org/docs/latest/api/http.html) for more details about the Node.js HTTP APIs.

0 commit comments

Comments
 (0)