Repository navigation
2026 06 24 upstream update - #6844
Conversation
When the moving of the v8::Global to the defer queue was extracted from Data::destroy() into the deferGlobalDestruction helper, it missed using the v8::Global move constructor. e.g. it went from ``` jsgIsolate.deferDestruction(v8::Global<v8::Data>(kj::mv(handle))); ``` to ``` jsgIsolate.deferDestruction(kj::mv(handle)); ``` This restores the missing move constructor use
The test file hardcoded ports 8080 and 9090 in ~20+ places. The wd_test macro generates three variants of each test (default, @all-compat-flags, @all-autogates) that run concurrently in CI as separate workerd processes on the same VM. All three would try to bind the same ports, causing the late ones to fail with EADDRINUSE. Switch every listen() call to use port 0 (kernel-assigned) and read back server.address().port. This is the standard Node pattern and the file already used it once for the listen-validation tests. The module-scope `globalServer.listen(9090)` plus the `GlobalService` class that referenced port 9090 directly are restructured around a shared module-scope port variable bound on the listen callback. Assisted-by: OpenCode:claude-opus-4.7
The previous sidecar supervisor pre-allocated ports by binding a socket to port 0, recording the kernel-assigned port, then closing the socket before spawning the sidecar. Between the close and the sidecar's bind, the kernel could hand out that port to an unrelated process, causing EADDRINUSE in the sidecar — the root cause of intermittent http-server-nodejs-test flakes on Linux CI, where processwrapper-sandbox provides no network isolation between concurrent test processes. Most sidecars now use a "sidecar reports its port" protocol: bind port 0, print "<ENV_VAR_NAME>=<PORT>" lines on stdout, and the supervisor reads those lines to populate the test's environment. No close-and-rebind gap, no possibility of port theft. JS sidecars also bind to SIDECAR_HOSTNAME (the randomized 127.x.x.x address) instead of all interfaces, so the random-hostname isolation actually applies. For sidecars that can't participate in the new protocol — currently just the WPT entrypoint, which is a shell wrapper around upstream wpt.py that reads `$HTTP_PORT` etc. from the environment — the supervisor falls back to the previous pre-allocate-and-set-env flow under SIDECAR_PORT_MODE=preallocate. This path retains the inherent close-then-rebind race; if it manifests as flakiness, the recommended recovery is bazel's existing flaky-test handling (`tags = ["flaky"]`). Assisted-by: OpenCode:claude-opus-4.7
The snapshot clone helper creates a temporary Docker-compatible container to copy snapshot volume contents. Cloudchamber's Docker-compatible create path expects Config.Entrypoint to be an array. Model ContainerCreateRequest.Entrypoint as a list and initialize the clone helper entrypoint through the typed Docker request schema. Add a regression test for array-form entrypoint encoding.
… 'gitlab' containers: Emit array entrypoint for snapshot clone helper Closes CC-7962 See merge request cloudflare/ew/workerd!308
…to 'gitlab' Fix EADDRINUSE flake in http-server-nodejs-test by using port 0 See merge request cloudflare/ew/workerd!293
Pin/Ptr/Weak for queue See merge request cloudflare/ew/workerd!287
This avoids a stack overflow if someone nests blockConcurrencyWhiles too deeply.
and remove package loading code paths. More cleanup after removing builtin packages.
Wind down CriticalSections iteratively instead of recursively. See merge request cloudflare/ew/workerd!314
Embed Python standard library modules in the Python bundle See merge request cloudflare/ew/workerd!299
Restore missing v8::Global(kj::mv(...)) See merge request cloudflare/ew/workerd!294
* sql: abort Cursor::toArray() before a fatal heap OOM A SQL query whose result set is too large to fit in memory can cause SqlStorage::Cursor::toArray() to drive the V8 heap straight into a fatal, process-killing OOM (v8::Utils::ReportOOMFailure). Because the accumulation happens entirely within one synchronous native callback, there is no yield point at which the normal exit-JS memory-limit enforcement can intervene. Poll IsolateLimitEnforcer::hasExcessivelyExceededHeapLimit() after each row is appended; condemning implementations flip it synchronously from a V8 NearHeapLimitCallback when the heap limit is crossed. When set, toArray() bails out with a catchable error instead of continuing toward a fatal OOM. The check is placed after appending a row so an already-condemned isolate doesn't throw a misleading error on an empty result set. Adds a test (and a settable heap-limit flag on the test fixture's mock isolate limit enforcer) covering the healthy, condemned, and empty-result-set cases. See merge request cloudflare/ew/workerd!312
sql: abort Cursor::toArray() before a fatal heap OOM See merge request cloudflare/ew/workerd!312
This reverts commit d8bafd9.
It is probably a mistake to nest blockConcurrencyWhile too deeply, and perhaps something we should add a hard limit on. Before we do, let's observe what production is like.
Theoretically, an application shouldn't need to nest blockConcurrencyWhile more than once or twice maybe, but doing it thousands of times definitely seems wrong. Let's add a limit.
* Effort 3: Adds test for a minimal package See merge request cloudflare/ew/workerd!322
Effort 2: Adds test for a minimal package See merge request cloudflare/ew/workerd!322
Add a metric reporting on critical section nesting depth. See merge request cloudflare/ew/workerd!315
Add a hard limit to nested CriticalSections. See merge request cloudflare/ew/workerd!326
* Address cf.vary type review feedback * add Workers cf.vary types See merge request cloudflare/ew/workerd!332
…to 'gitlab' add Workers cf.vary types See merge request cloudflare/ew/workerd!332
STOR-5107: Make process wide SQLite memory limits configurable per-cordon See merge request cloudflare/ew/workerd!330
Frankenvalue could previously only carry a capability when it was embedded inside a `v8Serialized` value, which requires running V8 serialization on a live object in a JS context. That makes it impossible to express a capability when constructing a Frankenvalue outside of any isolate -- e.g. from config or a control plane that wants to place a service binding (Fetcher) directly into `ctx.props`. Add a `capability` member to the Frankenvalue value union: an index into the node's base cap table plus a `workerd::rpc::SerializationTag` describing how to materialize it. `toJsImpl()` realizes it by invoking the deserializer registered for that tag (e.g. `Fetcher::deserialize` for `serviceStub`), so the io layer stays agnostic of the api-layer types. Add a `Frankenvalue::fromCapability()` factory for constructing such values, and bounds-check the index in `fromCapnp()` to keep cap-table slices in range.
Add an R2_BUCKET, KV_NAMESPACE serialization tag and give R2Bucket, KvNamespace a deserialize() thatreconstructs the binding from a Frankenvalue cap-table SubrequestChannel (serialize() throws). R2Bucket and KvNamespace can now be backed by a live channel as well as a channel number, so it works when carried as a capability (e.g. in ctx.props).
wd_rust_crate / wd_rust_binary link their rust_test (and rust_binary) with rustc driving the final link, which ignores Bazel's --custom_malloc and some other cc link settings. That is fine standalone, but an embedder may need these targets to link through the cc toolchain instead. Gate experimental_use_cc_common_link on @//build/config:rust_cc_common_link so an embedder can opt in. The setting is a dummy never-match here, so standalone workerd keeps the default rustc-driven link path (important, since standalone builds use non-hermetic system clang and shouldn't depend on toolchain features the embedder may rely on).
Let embedders opt Rust targets into cc_common.link See merge request cloudflare/ew/workerd!276
Add test-only unsafe Durable Object eviction support for workerd. This introduces server-side eviction plumbing that reuses the existing idle eviction path, then exposes it through unsafe.evict(stub, options) and unsafe.evictAllDurableObjects(options). The eviction path waits for live requests to drain, preserves durable storage, and hibernates hibernatable WebSockets by default. Callers can pass options.webSockets = "close" to close hibernatable WebSockets instead while still preserving storage and allowing the actor to be rebuilt on the next request. The implementation respects preventEviction and keeps actor broken-monitoring intact when eviction is skipped because the actor still has active references. The bulk path walks actor facets recursively so evictAllDurableObjects() covers the currently-running actor tree, waits for all sibling evictions before reporting errors, and keeps each eviction coroutine pinned while it can be suspended. Targeted eviction rejects non-Durable Object stubs and rejects objects that have not been instantiated yet, while bulk eviction skips idle/non-running actors. Tests cover storage preservation, in-memory state reset, in-flight requests, concurrent evictions, preventEviction, non-DO inputs, invalid options, bulk eviction, facet recursion, WebSocket hibernation, and WebSocket close mode.
STOR-5343: Add unsafe Durable Object eviction for tests See merge request cloudflare/ew/workerd!346
just format See merge request cloudflare/ew/workerd!351
merge github/main See merge request cloudflare/ew/workerd!353
Enables per-isolate JavaScript/TypeScript bootstrap See merge request cloudflare/ew/workerd!273
|
I have read the CLA Document and I hereby sign the CLA 19 out of 21 committers have signed the CLA. |
|
@mikea Bonk workflow was cancelled. View workflow run · To retry, trigger Bonk again. |
fix python lint See merge request cloudflare/ew/workerd!354
.gitlab-ci.yml, cfsetup.yaml and ci/build.yml configured CI for the internal GitLab copy of workerd that development used from May to August 2026. The first two syncs back to GitHub left them out, but the June 24 sync (cloudflare#6844) brought them in, and later syncs kept them. Nothing here runs them, and they name internal registries, Vault paths and CI components. The rest of ci/ is used by the dependency update tooling and stays. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
No description provided.