Skip to content

[world-vercel] Use undici for request HTTP 2 and automatic re-tries#1211

Merged
VaguelySerious merged 4 commits into
mainfrom
peter/undici
Feb 27, 2026
Merged

[world-vercel] Use undici for request HTTP 2 and automatic re-tries#1211
VaguelySerious merged 4 commits into
mainfrom
peter/undici

Conversation

@VaguelySerious
Copy link
Copy Markdown
Member

@VaguelySerious VaguelySerious commented Feb 27, 2026

  1. Automatic re-tries for most connection issues built-in, also observes re-try after if less than 30s away
  2. HTTP/2 multiplexing enabled (allowH2: true) — provides concurrent requests without head-of-line blocking
  3. HTTP/1.1 pipelining disabled (pipelining: 1) — pipelining deadlocks the webhook respondWith: 'manual' mechanism because the webhook handler and workflow handler share connections via
    the same Agent
  4. Streaming calls excluded from H2 dispatcher — undici's experimental H2 client hangs on both streaming writes (duplex: 'half' PUT) and streaming reads (long-lived GET responses).

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Feb 27, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
example-nextjs-workflow-turbopack Ready Ready Preview, Comment Feb 27, 2026 9:45pm
example-nextjs-workflow-webpack Ready Ready Preview, Comment Feb 27, 2026 9:45pm
example-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-astro-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-express-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-fastify-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-hono-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-nitro-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-nuxt-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-sveltekit-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workbench-vite-workflow Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workflow-docs Ready Ready Preview, Comment, Open in v0 Feb 27, 2026 9:45pm
workflow-nest Ready Ready Preview, Comment Feb 27, 2026 9:45pm
workflow-swc-playground Ready Ready Preview, Comment Feb 27, 2026 9:45pm

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Feb 27, 2026

🦋 Changeset detected

Latest commit: 40493fa

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 17 packages
Name Type
@workflow/world-vercel Patch
@workflow/world-local Patch
@workflow/cli Patch
@workflow/core Patch
@workflow/world-postgres Patch
workflow Patch
@workflow/world-testing Patch
@workflow/builders Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/web-shared Patch
@workflow/astro Patch
@workflow/nest Patch
@workflow/rollup Patch
@workflow/sveltekit Patch
@workflow/vite Patch
@workflow/nuxt Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 27, 2026

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Express 0.031s (-11.5% 🟢) 1.006s (~) 0.974s 10 1.00x
💻 Local Nitro 0.034s (+4.0%) 1.005s (~) 0.972s 10 1.07x
🐘 Postgres Express 0.041s (-33.3% 🟢) 1.011s (~) 0.971s 10 1.29x
💻 Local Next.js (Turbopack) 0.043s (+5.7% 🔺) 1.005s (~) 0.962s 10 1.36x
🌐 Redis Next.js (Turbopack) 0.043s (-5.3% 🟢) 1.005s (~) 0.962s 10 1.38x
🐘 Postgres Nitro 0.051s (-8.4% 🟢) 1.011s (~) 0.960s 10 1.63x
🌐 MongoDB Next.js (Turbopack) 0.076s (-17.8% 🟢) 1.007s (~) 0.931s 10 2.44x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 0.492s (-20.9% 🟢) 1.975s (-2.9%) 1.483s 10 1.00x
▲ Vercel Express 0.506s (-25.6% 🟢) 2.020s (-4.7%) 1.514s 10 1.03x
▲ Vercel Next.js (Turbopack) 0.511s (-25.2% 🟢) 1.916s (-15.5% 🟢) 1.405s 10 1.04x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.099s (-3.1%) 2.012s (~) 0.913s 10 1.00x
💻 Local Next.js (Turbopack) 1.100s (~) 2.005s (~) 0.905s 10 1.00x
💻 Local Express 1.103s (-0.9%) 2.005s (~) 0.903s 10 1.00x
🌐 Redis Next.js (Turbopack) 1.105s (~) 2.006s (~) 0.901s 10 1.01x
💻 Local Nitro 1.108s (~) 2.005s (~) 0.897s 10 1.01x
🐘 Postgres Nitro 1.134s (~) 2.011s (~) 0.877s 10 1.03x
🌐 MongoDB Next.js (Turbopack) 1.305s (~) 2.007s (~) 0.702s 10 1.19x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.096s (-11.5% 🟢) 3.433s (-3.3%) 1.337s 10 1.00x
▲ Vercel Express 2.103s (-5.2% 🟢) 3.290s (-3.4%) 1.187s 10 1.00x
▲ Vercel Next.js (Turbopack) 2.442s (+11.3% 🔺) 3.574s (+6.4% 🔺) 1.132s 10 1.16x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 10.659s (-2.1%) 11.038s (~) 0.379s 3 1.00x
🌐 Redis Next.js (Turbopack) 10.721s (~) 11.023s (~) 0.302s 3 1.01x
💻 Local Next.js (Turbopack) 10.772s (~) 11.023s (~) 0.250s 3 1.01x
💻 Local Express 10.824s (-0.7%) 11.021s (~) 0.196s 3 1.02x
💻 Local Nitro 10.867s (~) 11.023s (~) 0.156s 3 1.02x
🐘 Postgres Nitro 10.877s (~) 11.041s (~) 0.164s 3 1.02x
🌐 MongoDB Next.js (Turbopack) 12.216s (~) 13.018s (~) 0.802s 3 1.15x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 16.584s (~) 17.876s (+0.6%) 1.292s 2 1.00x
▲ Vercel Express 17.295s (+3.3%) 18.341s (+2.5%) 1.046s 2 1.04x
▲ Vercel Next.js (Turbopack) 17.544s (+0.6%) 19.217s (+1.5%) 1.673s 2 1.06x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 26.715s (-2.0%) 27.058s (-3.6%) 0.343s 3 1.00x
🌐 Redis Next.js (Turbopack) 26.915s (~) 27.051s (~) 0.136s 3 1.01x
🐘 Postgres Nitro 27.258s (~) 28.066s (~) 0.808s 3 1.02x
💻 Local Next.js (Turbopack) 27.314s (~) 28.052s (~) 0.737s 3 1.02x
💻 Local Express 27.502s (-0.8%) 28.049s (~) 0.548s 3 1.03x
💻 Local Nitro 27.573s (~) 28.052s (~) 0.479s 3 1.03x
🌐 MongoDB Next.js (Turbopack) 30.519s (~) 31.046s (~) 0.527s 2 1.14x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 43.275s (-7.3% 🟢) 44.363s (-7.7% 🟢) 1.088s 2 1.00x
▲ Vercel Next.js (Turbopack) 43.682s (-5.6% 🟢) 45.267s (-4.2%) 1.584s 2 1.01x
▲ Vercel Express 44.078s (-2.6%) 45.422s (-3.0%) 1.344s 2 1.02x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 54.082s (-2.1%) 54.597s (-2.7%) 0.515s 2 1.00x
🌐 Redis Next.js (Turbopack) 54.438s (~) 55.098s (~) 0.659s 2 1.01x
🐘 Postgres Nitro 55.130s (~) 55.604s (+0.9%) 0.474s 2 1.02x
💻 Local Next.js (Turbopack) 57.079s (+0.6%) 57.603s (+0.9%) 0.524s 2 1.06x
💻 Local Express 57.201s (-0.9%) 58.096s (~) 0.895s 2 1.06x
💻 Local Nitro 57.542s (~) 58.102s (~) 0.559s 2 1.06x
🌐 MongoDB Next.js (Turbopack) 60.938s (~) 61.062s (~) 0.123s 2 1.13x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 94.415s (-2.6%) 95.274s (-3.1%) 0.859s 1 1.00x
▲ Vercel Next.js (Turbopack) 95.280s (-3.2%) 96.310s (-3.6%) 1.030s 1 1.01x
▲ Vercel Express 95.360s (-3.6%) 96.794s (-3.4%) 1.434s 1 1.01x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.261s (+0.7%) 2.006s (~) 0.746s 15 1.00x
🐘 Postgres Express 1.323s (-3.9%) 2.010s (~) 0.687s 15 1.05x
🐘 Postgres Nitro 1.397s (~) 2.011s (~) 0.614s 15 1.11x
💻 Local Express 1.410s (~) 2.004s (~) 0.594s 15 1.12x
💻 Local Nitro 1.415s (+0.5%) 2.005s (~) 0.590s 15 1.12x
💻 Local Next.js (Turbopack) 1.442s (+2.9%) 2.005s (~) 0.563s 15 1.14x
🌐 MongoDB Next.js (Turbopack) 2.153s (~) 3.007s (~) 0.853s 10 1.71x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.368s (-3.3%) 3.505s (-3.6%) 1.137s 9 1.00x
▲ Vercel Nitro 2.398s (-23.0% 🟢) 3.498s (-19.3% 🟢) 1.101s 9 1.01x
▲ Vercel Express 3.109s (+15.5% 🔺) 4.329s (+22.4% 🔺) 1.221s 7 1.31x

🔍 Observability: Next.js (Turbopack) | Nitro | Express

Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.767s (-13.4% 🟢) 2.011s (-22.7% 🟢) 0.245s 15 1.00x
🐘 Postgres Nitro 1.993s (-0.8%) 2.513s (~) 0.520s 12 1.13x
🌐 Redis Next.js (Turbopack) 2.500s (~) 3.008s (~) 0.508s 10 1.42x
💻 Local Nitro 2.617s (+0.6%) 3.008s (~) 0.391s 10 1.48x
💻 Local Express 2.618s (+2.9%) 3.007s (~) 0.390s 10 1.48x
💻 Local Next.js (Turbopack) 2.619s (+3.4%) 3.008s (+3.1%) 0.388s 10 1.48x
🌐 MongoDB Next.js (Turbopack) 4.580s (-3.5%) 5.176s (~) 0.596s 6 2.59x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.796s (-6.6% 🟢) 3.977s (-4.3%) 1.180s 8 1.00x
▲ Vercel Next.js (Turbopack) 2.972s (-10.1% 🟢) 3.818s (-13.9% 🟢) 0.845s 8 1.06x
▲ Vercel Express 3.922s (+32.2% 🔺) 5.139s (+27.8% 🔺) 1.216s 6 1.40x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 2.652s (-20.1% 🟢) 3.682s (-8.4% 🟢) 1.029s 9 1.00x
🐘 Postgres Nitro 3.909s (+8.1% 🔺) 4.449s (~) 0.540s 7 1.47x
🌐 Redis Next.js (Turbopack) 4.048s (~) 4.582s (~) 0.534s 7 1.53x
💻 Local Express 7.272s (-2.2%) 8.020s (~) 0.748s 4 2.74x
💻 Local Nitro 7.516s (-2.5%) 8.016s (~) 0.500s 4 2.83x
💻 Local Next.js (Turbopack) 7.840s (+17.6% 🔺) 8.268s (+17.9% 🔺) 0.428s 4 2.96x
🌐 MongoDB Next.js (Turbopack) 9.743s (-0.6%) 10.350s (~) 0.606s 3 3.67x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 3.087s (+4.4%) 4.139s (~) 1.052s 8 1.00x
▲ Vercel Next.js (Turbopack) 3.677s (+10.3% 🔺) 4.751s (-7.3% 🟢) 1.074s 7 1.19x
▲ Vercel Express 4.375s (+54.7% 🔺) 5.276s (+32.7% 🔺) 0.901s 6 1.42x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.251s (-2.1%) 2.006s (~) 0.755s 15 1.00x
🐘 Postgres Express 1.287s (-7.8% 🟢) 2.011s (~) 0.723s 15 1.03x
🐘 Postgres Nitro 1.387s (+1.4%) 2.010s (~) 0.623s 15 1.11x
💻 Local Express 1.432s (-2.4%) 2.005s (~) 0.573s 15 1.14x
💻 Local Next.js (Turbopack) 1.435s (+4.0%) 2.005s (~) 0.570s 15 1.15x
💻 Local Nitro 1.443s (+1.8%) 2.005s (~) 0.562s 15 1.15x
🌐 MongoDB Next.js (Turbopack) 2.170s (~) 3.007s (~) 0.838s 10 1.73x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.358s (+9.3% 🔺) 3.576s (+4.4%) 1.218s 9 1.00x
▲ Vercel Nitro 2.378s (-12.0% 🟢) 4.027s (+3.2%) 1.649s 8 1.01x
▲ Vercel Next.js (Turbopack) 3.858s (+67.4% 🔺) 6.820s (+94.2% 🔺) 2.962s 5 1.64x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.837s (-7.6% 🟢) 2.227s (-11.5% 🟢) 0.390s 14 1.00x
🐘 Postgres Nitro 2.050s (+3.1%) 2.739s (+9.0% 🔺) 0.689s 11 1.12x
🌐 Redis Next.js (Turbopack) 2.513s (+1.2%) 3.008s (~) 0.494s 10 1.37x
💻 Local Express 2.699s (+0.7%) 3.007s (~) 0.308s 10 1.47x
💻 Local Nitro 2.776s (+1.2%) 3.008s (~) 0.232s 10 1.51x
💻 Local Next.js (Turbopack) 2.804s (+6.4% 🔺) 3.108s (+3.3%) 0.304s 10 1.53x
🌐 MongoDB Next.js (Turbopack) 4.682s (~) 5.177s (~) 0.495s 6 2.55x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.650s (-6.6% 🟢) 3.767s (-3.8%) 1.117s 8 1.00x
▲ Vercel Nitro 2.756s (-21.6% 🟢) 3.966s (-14.5% 🟢) 1.209s 8 1.04x
▲ Vercel Express 2.979s (+11.7% 🔺) 4.131s (+3.5%) 1.152s 8 1.12x

🔍 Observability: Next.js (Turbopack) | Nitro | Express

Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 3.075s (-8.8% 🟢) 3.891s (-3.2%) 0.815s 8 1.00x
🐘 Postgres Nitro 3.877s (+9.3% 🔺) 4.465s (+7.6% 🔺) 0.588s 7 1.26x
🌐 Redis Next.js (Turbopack) 4.078s (+1.6%) 4.868s (+9.7% 🔺) 0.790s 7 1.33x
💻 Local Express 8.158s (+1.1%) 8.521s (~) 0.363s 4 2.65x
💻 Local Nitro 8.384s (+1.2%) 9.020s (~) 0.636s 4 2.73x
💻 Local Next.js (Turbopack) 8.616s (+13.4% 🔺) 9.018s (+12.5% 🔺) 0.402s 4 2.80x
🌐 MongoDB Next.js (Turbopack) 10.108s (+3.1%) 10.347s (~) 0.239s 3 3.29x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.384s (+18.6% 🔺) 4.291s (+8.6% 🔺) 0.907s 7 1.00x
▲ Vercel Next.js (Turbopack) 3.806s (+28.5% 🔺) 4.739s (+20.4% 🔺) 0.933s 8 1.12x
▲ Vercel Nitro 4.481s (+43.8% 🔺) 5.772s (+34.7% 🔺) 1.291s 6 1.32x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Stream Benchmarks (includes TTFB metrics)
workflow with stream

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 0.146s (-25.2% 🟢) 0.998s (+0.7%) 0.002s (+7.1% 🔺) 1.012s (~) 0.866s 10 1.00x
💻 Local Next.js (Turbopack) 0.147s (+5.7% 🔺) 1.001s (~) 0.011s (+0.9%) 1.016s (~) 0.869s 10 1.01x
🌐 Redis Next.js (Turbopack) 0.150s (+2.2%) 1.000s (~) 0.001s (-7.1% 🟢) 1.007s (~) 0.857s 10 1.03x
💻 Local Express 0.174s (-7.4% 🟢) 1.002s (~) 0.011s (~) 1.016s (~) 0.842s 10 1.20x
💻 Local Nitro 0.184s (+5.3% 🔺) 1.002s (~) 0.012s (+6.1% 🔺) 1.018s (~) 0.834s 10 1.26x
🐘 Postgres Nitro 0.203s (+6.2% 🔺) 0.994s (~) 0.002s (-5.9% 🟢) 1.012s (~) 0.809s 10 1.39x
🌐 MongoDB Next.js (Turbopack) 0.471s (-2.8%) 0.975s (+1.3%) 0.002s (~) 1.008s (~) 0.537s 10 3.23x
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 1.575s (-10.3% 🟢) 2.194s (+1.0%) 0.128s (-5.9% 🟢) 2.769s (-3.3%) 1.194s 10 1.00x
▲ Vercel Express 1.740s (-3.2%) 2.519s (-15.4% 🟢) 0.614s (+311.3% 🔺) 33.539s (~) 31.799s 10 1.10x
▲ Vercel Nitro 1.775s (~) 2.509s (+2.4%) 0.099s (-84.2% 🟢) 63.102s (+1615.8% 🔺) 61.326s 10 1.13x

🔍 Observability: Next.js (Turbopack) | Express | Nitro

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World 🥇 Fastest Framework Wins
💻 Local Express 6/12
🐘 Postgres Express 12/12
▲ Vercel Nitro 7/12
Fastest World by Framework

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 🐘 Postgres 11/12
Next.js (Turbopack) 🌐 Redis 7/12
Nitro 🐘 Postgres 7/12
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 27, 2026

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 523 0 49 572
✅ 💻 Local Development 556 0 68 624
✅ 📦 Local Production 556 0 68 624
✅ 🐘 Local Postgres 556 0 68 624
✅ 🪟 Windows 49 0 3 52
❌ 🌍 Community Worlds 112 47 9 168
✅ 📋 Other 135 0 21 156
Total 2487 47 286 2820

❌ Failed Tests

🌍 Community Worlds (47 failed)

mongodb (1 failed):

  • webhookWorkflow

turso (46 failed):

  • addTenWorkflow
  • addTenWorkflow
  • should work with react rendering in step
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • hookWorkflow
  • webhookWorkflow
  • sleepingWorkflow
  • parallelSleepWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling retry behavior workflow completes despite transient 5xx on step_completed
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
  • Calculator.calculate - static workflow method using static step methods from another class
  • AllInOneService.processNumber - static workflow method using sibling static step methods
  • ChainableService.processWithThis - static step methods using this to reference the class
  • thisSerializationWorkflow - step function invoked with .call() and .apply()
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE
  • instanceMethodStepWorkflow - instance methods with "use step" directive
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument
  • cancelRun - cancelling a running workflow
  • cancelRun via CLI - cancelling a running workflow
  • pages router addTenWorkflow via pages router
  • pages router promiseAllWorkflow via pages router
  • pages router sleepingWorkflow via pages router

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 47 0 5
✅ example 47 0 5
✅ express 47 0 5
✅ fastify 47 0 5
✅ hono 47 0 5
✅ nextjs-turbopack 50 0 2
✅ nextjs-webpack 50 0 2
✅ nitro 47 0 5
✅ nuxt 47 0 5
✅ sveltekit 47 0 5
✅ vite 47 0 5
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 45 0 7
✅ express-stable 45 0 7
✅ fastify-stable 45 0 7
✅ hono-stable 45 0 7
✅ nextjs-turbopack-canary 49 0 3
✅ nextjs-turbopack-stable 49 0 3
✅ nextjs-webpack-canary 49 0 3
✅ nextjs-webpack-stable 49 0 3
✅ nitro-stable 45 0 7
✅ nuxt-stable 45 0 7
✅ sveltekit-stable 45 0 7
✅ vite-stable 45 0 7
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 45 0 7
✅ express-stable 45 0 7
✅ fastify-stable 45 0 7
✅ hono-stable 45 0 7
✅ nextjs-turbopack-canary 49 0 3
✅ nextjs-turbopack-stable 49 0 3
✅ nextjs-webpack-canary 49 0 3
✅ nextjs-webpack-stable 49 0 3
✅ nitro-stable 45 0 7
✅ nuxt-stable 45 0 7
✅ sveltekit-stable 45 0 7
✅ vite-stable 45 0 7
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 45 0 7
✅ express-stable 45 0 7
✅ fastify-stable 45 0 7
✅ hono-stable 45 0 7
✅ nextjs-turbopack-canary 49 0 3
✅ nextjs-turbopack-stable 49 0 3
✅ nextjs-webpack-canary 49 0 3
✅ nextjs-webpack-stable 49 0 3
✅ nitro-stable 45 0 7
✅ nuxt-stable 45 0 7
✅ sveltekit-stable 45 0 7
✅ vite-stable 45 0 7
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 49 0 3
❌ 🌍 Community Worlds
App Passed Failed Skipped
✅ mongodb-dev 3 0 0
❌ mongodb 49 1 3
✅ redis-dev 3 0 0
✅ redis 50 0 3
✅ turso-dev 3 0 0
❌ turso 4 46 3
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 45 0 7
✅ e2e-local-postgres-nest-stable 45 0 7
✅ e2e-local-prod-nest-stable 45 0 7

📋 View full workflow run

Comment thread packages/world-vercel/src/http-client.ts Outdated
@socket-security
Copy link
Copy Markdown

socket-security Bot commented Feb 27, 2026

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatednpm/​turbo@​2.8.11 ⏵ 2.8.121001008597100

View full report

VaguelySerious and others added 3 commits February 27, 2026 11:59
Add a shared undici Agent (wrapped in RetryAgent) as the fetch dispatcher
for all outgoing HTTP calls in world-vercel. This provides:

- HTTP/2 multiplexing via ALPN negotiation (allowH2: true)
- Connection pooling (128 connections per origin)
- Automatic retry on 429/5xx with Retry-After header support

Streaming write operations (writeToStream, writeToStreamMulti, closeStream)
are excluded from the H2 dispatcher because undici's HTTP/2 client hangs
when combined with request bodies on PUT endpoints. Read-only stream calls
(readFromStream, listStreamsByRunId) safely use the dispatcher.

HTTP/1.1 pipelining is left at 1 (disabled) to avoid head-of-line blocking
that deadlocks the webhook respondWith mechanism. HTTP/2 multiplexing
provides the same throughput benefit without this problem.

Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
test.skipIf(isLocalDeployment())(
'readableStreamWorkflow',
{ timeout: 60_000 },
{ timeout: 80_000 },
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:'(

need to tackle improving test perf, especially in my benchmark PR

const response = await fetch(
new Request(url, { method: 'GET', headers })
);
const response = await fetch(url, {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we not use undici.request / undici.pipeline for maximum performance (as per undici's README where they recommend that to using fetch

// Observe Retry-After header if received
retryAfter: true,
// By default, we observe re-try headers, and also separately
// re-try on these status codes: 429 / 500 / 502 / 503 / 504.
Copy link
Copy Markdown
Member

@TooTallNate TooTallNate Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these status codes retried by default? I'm not seeing any relevant configuration for them.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes

method: 'PUT',
body: chunk,
headers: httpConfig.headers,
duplex: 'half',
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you explain why you're removing duplex: 'half'?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a comment saying:

 * IMPORTANT: This dispatcher must NOT be used with `duplex: 'half'`
 * streaming requests — undici's H2 client hangs when combined with
 * half-duplex streams. See streamer.ts for the streaming code path.

headers,
});
const response = await fetch(request);
const response = await fetch(request, {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same. shouldn't we use undici.request for max performance over fetch?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude didn't get it working, and the overhead is 0.001% or something, I think it's fine. H2 is what matters

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that also apparently undici.request() does not follow redirects by default, but fetch() does - so we should be careful about that (we want to follow redirects to leave the option open to redirect to S3 for the refs):

Yes, fetch() follows HTTP redirects by default, even when using undici's custom dispatcher. The key distinction is:

- undici's Agent.dispatch() / Agent.request() — maxRedirections defaults to 0 (no redirect following). This is the low-level undici API.
- fetch() (the Fetch API) — redirect defaults to 'follow' per the Fetch spec (request.js:850). This is true regardless of which dispatcher is used, because redirect handling is implemented in the Fetch spec layer (lib/web/fetch/index.js:1194), not in the dispatcher layer.

Since the PR uses fetch() with dispatcher: getDispatcher(), redirects will be followed (up to 20 times per the Fetch spec, index.js:1247). The Agent's maxRedirections: 0 setting only applies to undici's own client.request() / client.dispatch() APIs, not to fetch().

Comment thread packages/world-vercel/package.json Outdated
"@workflow/errors": "workspace:*",
"@workflow/world": "workspace:*",
"cbor-x": "1.6.0",
"undici": "6.22.0",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we use undici@7? I know there were some issues when I tried to bump it but maybe coudl spend some cycles to just upgrade to 7?

also we should probably put undici in catalog since local world also uses it and we should pin versions across all undici uage in our monorepo

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure! Will do

Copy link
Copy Markdown
Member

@TooTallNate TooTallNate left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solid infrastructure improvement. The HTTP/2 multiplexing and automatic retry via undici's RetryAgent are good wins. The streaming exclusion from H2 is well-documented and the reasoning is sound. A few observations inline.

);
}
return _dispatcher;
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The module-level singleton means the dispatcher lives for the entire process lifetime with no way to shut it down. In serverless / short-lived processes this is fine, but if this code ever runs in a long-lived dev server or test suite, the 128 connections and keep-alive timers could leak.

Consider adding a closeDispatcher() export (or making it configurable via APIConfig) for test teardown. Not blocking, but worth noting.

// By default, we observe re-try headers, and also separately
// re-try on these status codes: 429 / 500 / 502 / 503 / 504.
// TODO: We might want to let 429s pass through, so that we can do
// runtime retry-after handling through the queue.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The TODO about letting 429s pass through is worth tracking. With RetryAgent retrying 429s up to 5 times (the default maxRetries), and makeRequest in utils.ts also parsing Retry-After headers and throwing WorkflowAPIError with retryAfter for the queue system to handle — there's now a layered retry: undici retries 5 times silently, and only if all 5 fail does the application-level retry kick in.

This is probably fine (belt and suspenders), but the comment on utils.ts:306 ("RetryAgent handles most 429 retries automatically, but this catches the case where retries are exhausted") correctly documents it. Just want to flag that the total retry budget is now 5 * (undici retries) + queue-level retries, which could delay error surfacing.

headers: httpConfig.headers,
}
);
await response.text();
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good addition — await response.text() ensures the response body is fully consumed, preventing connection leaks with HTTP/1.1 keep-alive. Without this, unconsumed bodies can hold connections open.

One thing: if the server returns an error status (e.g. 500), this silently discards the error body. The write methods don't check response.ok. Was this intentional? If these endpoints can fail, you might want at least a status check before the early return.

Comment thread packages/world-vercel/src/streamer.ts Outdated
// streaming calls. undici's experimental HTTP/2 client hangs on both
// streaming writes (PUT with body) and streaming reads (long-lived GET
// responses). Standard request/response calls (makeRequest, encryption,
// refs) work fine with H2.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is clear and well-placed. Since this is a critical constraint, consider also adding a brief note about why the streaming calls don't use the dispatcher at all (not even for retry) — i.e., streaming writes are fire-and-forget with Uint8Array bodies (not ReadableStream), so duplex: 'half' is no longer needed, but the H2 dispatcher is still excluded because the retry behavior could cause duplicate stream writes.

Comment thread packages/world-vercel/src/utils.ts Outdated
const response = await fetch(request);
const response = await fetch(request, {
dispatcher: getDispatcher(),
} as RequestInit);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: fetch(request, { dispatcher } as RequestInit) — passing a Request object as the first argument and options as the second is a valid pattern, but note that undici's dispatcher option is read from the second argument. If Request already has a body, some implementations may not respect the dispatcher from the second arg. This works in practice with Node's built-in fetch (which is undici under the hood), but it's a subtle API surface. Just flagging for awareness.

Comment thread packages/world-vercel/src/refs.ts
Comment thread packages/world-vercel/src/encryption.test.ts
@VaguelySerious
Copy link
Copy Markdown
Member Author

Updated to undici 7 and addressed feedback, waiting for CI

Add a shared undici Agent (wrapped in RetryAgent) as the fetch dispatcher
for all outgoing HTTP calls in world-vercel. Upgrade undici to v7 and
share the version via pnpm catalog between world-vercel and world-local.

- HTTP/2 multiplexing via ALPN negotiation (allowH2: true)
- Connection pooling (128 connections per origin)
- Automatic retry on 429/5xx with Retry-After header support

Streaming calls in streamer.ts are excluded from the H2 dispatcher
because undici's HTTP/2 client hangs on both streaming writes and
long-lived streaming reads.

Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants