Skip to content

[core] Fix abort signal not reflected in subsequent step (replay-ordering flake)#2412

Draft
VaguelySerious wants to merge 2 commits into
mainfrom
peter/fix-abort-signal-replay-ordering
Draft

[core] Fix abort signal not reflected in subsequent step (replay-ordering flake)#2412
VaguelySerious wants to merge 2 commits into
mainfrom
peter/fix-abort-signal-replay-ordering

Conversation

@VaguelySerious

@VaguelySerious VaguelySerious commented Jun 14, 2026

Copy link
Copy Markdown
Member

Problem

The E2E test abortFromStepWorkflow: step abort cancels an in-flight sibling step flakes with stepSawAborted === false. The workflow aborts a controller from one step (abortFromStep), then — after the parallel work settles — passes controller.signal to a subsequent step (checkSignalState), which reads aborted: false. (workflowAborted and the in-flight sibling's stream-based cancel are unaffected, which is the tell.)

Root cause (two parts)

When a step aborts a controller, the abort is reflected into the workflow VM via a hook_received event. Two independent ordering gaps let checkSignalState serialize a stale, non-aborted signal:

  1. Durable abort flushed in the background. The step-side abort() records the durable hook_received event via an op pushed into ctx.ops, which is flushed in the background (safeWaitUntil) — not awaited before step_completed is written or before the workflow continuation is enqueued. So the continuation can resolve Promise.all and dispatch checkSignalState before hook_received exists. This is the dominant cause.

  2. Suspension gate ignored the abort delivery. Even when hook_received is in the log, the consumer's _setAborted is deferred behind await hydrateStepReturnValue(...) (async reason decrypt/deserialize) on the promiseQueue. Step-result and hook-payload deliveries bump ctx.pendingDeliveries so the suspension handler waits for them before dehydrating the next step's arguments; the abort delivery did not, so the suspension could serialize checkSignalState's signal before the abort landed.

Fix

  • Ordering: add a preCompletionOps bucket to the step context for operations that must be durable before the step's terminal event. Route the abort's hook resume there (keeping the real-time stream write in the background ops, since it must reach the in-flight sibling ASAP). Await it before step_completed/step_failed in both the queue step handler and the inline step executor.
  • Suspension gate: bump ctx.pendingDeliveries around the abort delivery so the suspension waits for _setAborted before dehydrating downstream step arguments.

Together: the continuation now both has hook_received in its event log and waits for its hydration before serializing the next step's signal.

Tests

  • abort-replay-ordering.test.ts — injects hydration latency past a macrotask; asserts the suspension/idle gate only fires once the signal has aborted, and the in-flight abort is counted as a pending delivery.
  • abort-controller-step.test.ts — new test exercising the real reviveAbortController via hydrateStepArguments; asserts the durable hook resume is routed to preCompletionOps (not the background ops) and fires with the correct payload when that bucket is drained.

Both fail against the pre-fix code and pass with the fix. Existing abort/step/suspension/workflow suites pass (542 tests in the runtime+workflow sweep).

An AbortController aborted from a step is reflected into the workflow VM
via a hook_received event, but _setAborted was deferred behind an async
hydrateStepReturnValue (reason decrypt/deserialize) on the promiseQueue.
Unlike step-result and hook-payload deliveries, the abort delivery did
not participate in ctx.pendingDeliveries, so scheduleWhenIdle (which the
suspension handler uses to gate dehydration of queued step arguments)
could fire while the abort was still in flight. A step dispatched right
after the abort that received controller.signal then had its arguments
serialized with aborted=false.

Bump pendingDeliveries around the abort delivery so the suspension waits
for _setAborted to land, matching the existing step/hook-payload pattern.
This fixes the intermittent abortFromStepWorkflow E2E failure
(stepSawAborted=false).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

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 Jun 14, 2026 11:13am
example-nextjs-workflow-webpack Ready Ready Preview, Comment Jun 14, 2026 11:13am
example-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-astro-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-express-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-fastify-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-hono-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-nitro-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-nuxt-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-sveltekit-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-tanstack-start-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workbench-vite-workflow Ready Ready Preview, Comment Jun 14, 2026 11:13am
workflow-docs Ready Ready Preview, Comment, Open in v0 Jun 14, 2026 11:13am
workflow-swc-playground Ready Ready Preview, Comment Jun 14, 2026 11:13am
workflow-tarballs Ready Ready Preview, Comment Jun 14, 2026 11:13am
workflow-web Ready Ready Preview, Comment Jun 14, 2026 11:13am

@changeset-bot

changeset-bot Bot commented Jun 14, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 6c1164f

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

This PR includes changesets to release 16 packages
Name Type
@workflow/core Patch
@workflow/builders Patch
@workflow/cli Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/vitest Patch
@workflow/web-shared Patch
@workflow/web Patch
workflow Patch
@workflow/world-testing 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

github-actions Bot commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

All tests passed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 1442 0 219 1661
✅ 💻 Local Development 1895 0 219 2114
✅ 📦 Local Production 1895 0 219 2114
✅ 🐘 Local Postgres 1881 0 233 2114
✅ 🪟 Windows 151 0 0 151
✅ 📋 Other 879 0 178 1057
Total 8143 0 1068 9211

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 125 0 26
✅ example 125 0 26
✅ express 125 0 26
✅ fastify 125 0 26
✅ hono 125 0 26
✅ nextjs-turbopack 149 0 2
✅ nextjs-webpack 149 0 2
✅ nitro 125 0 26
✅ nuxt 125 0 26
✅ sveltekit 144 0 7
✅ vite 125 0 26
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 126 0 25
✅ express-stable 126 0 25
✅ fastify-stable 126 0 25
✅ hono-stable 126 0 25
✅ nextjs-turbopack-canary 132 0 19
✅ nextjs-turbopack-stable-lazy-discovery-disabled 151 0 0
✅ nextjs-turbopack-stable-lazy-discovery-enabled 151 0 0
✅ nextjs-webpack-canary 132 0 19
✅ nextjs-webpack-stable-lazy-discovery-disabled 151 0 0
✅ nextjs-webpack-stable-lazy-discovery-enabled 151 0 0
✅ nitro-stable 126 0 25
✅ nuxt-stable 126 0 25
✅ sveltekit-stable 145 0 6
✅ vite-stable 126 0 25
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 126 0 25
✅ express-stable 126 0 25
✅ fastify-stable 126 0 25
✅ hono-stable 126 0 25
✅ nextjs-turbopack-canary 132 0 19
✅ nextjs-turbopack-stable-lazy-discovery-disabled 151 0 0
✅ nextjs-turbopack-stable-lazy-discovery-enabled 151 0 0
✅ nextjs-webpack-canary 132 0 19
✅ nextjs-webpack-stable-lazy-discovery-disabled 151 0 0
✅ nextjs-webpack-stable-lazy-discovery-enabled 151 0 0
✅ nitro-stable 126 0 25
✅ nuxt-stable 126 0 25
✅ sveltekit-stable 145 0 6
✅ vite-stable 126 0 25
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 125 0 26
✅ express-stable 125 0 26
✅ fastify-stable 125 0 26
✅ hono-stable 125 0 26
✅ nextjs-turbopack-canary 131 0 20
✅ nextjs-turbopack-stable-lazy-discovery-disabled 150 0 1
✅ nextjs-turbopack-stable-lazy-discovery-enabled 150 0 1
✅ nextjs-webpack-canary 131 0 20
✅ nextjs-webpack-stable-lazy-discovery-disabled 150 0 1
✅ nextjs-webpack-stable-lazy-discovery-enabled 150 0 1
✅ nitro-stable 125 0 26
✅ nuxt-stable 125 0 26
✅ sveltekit-stable 144 0 7
✅ vite-stable 125 0 26
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 151 0 0
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 126 0 25
✅ e2e-local-dev-tanstack-start- 126 0 25
✅ e2e-local-postgres-nest-stable 125 0 26
✅ e2e-local-postgres-tanstack-start- 125 0 26
✅ e2e-local-prod-nest-stable 126 0 25
✅ e2e-local-prod-tanstack-start- 126 0 25
✅ e2e-vercel-prod-tanstack-start 125 0 26

📋 View full workflow run

@github-actions

github-actions Bot commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

📊 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 🥇 Nitro 0.046s (-4.2%) 1.006s (~) 0.961s 10 1.00x
💻 Local Express 0.046s (+8.0% 🔺) 1.007s (~) 0.961s 10 1.00x
🐘 Postgres Nitro 0.059s (-8.2% 🟢) 1.012s (~) 0.953s 10 1.29x
🐘 Postgres Express 0.064s (+4.8%) 1.012s (~) 0.948s 10 1.39x
🐘 Postgres Next.js (Turbopack) 0.071s (+6.7% 🔺) 1.011s (~) 0.940s 10 1.56x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 0.254s (-3.2%) 2.190s (-7.1% 🟢) 1.936s 10 1.00x
▲ Vercel Next.js (Turbopack) 0.266s (-33.9% 🟢) 2.315s (-9.1% 🟢) 2.049s 10 1.05x
▲ Vercel Express 0.336s (+5.0%) 2.417s (+5.6% 🔺) 2.081s 10 1.32x

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

workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Express 1.101s (~) 2.006s (~) 0.905s 10 1.00x
💻 Local Nitro 1.106s (+0.5%) 2.007s (~) 0.901s 10 1.00x
🐘 Postgres Express 1.109s (~) 2.008s (~) 0.899s 10 1.01x
🐘 Postgres Nitro 1.111s (~) 2.010s (~) 0.899s 10 1.01x
🐘 Postgres Next.js (Turbopack) 1.175s (+1.7%) 2.009s (~) 0.834s 10 1.07x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 1.573s (-6.0% 🟢) 4.123s (+12.2% 🔺) 2.550s 10 1.00x
▲ Vercel Nitro 1.675s (+2.3%) 3.676s (-3.2%) 2.001s 10 1.07x
▲ Vercel Next.js (Turbopack) 1.696s (+2.9%) 3.899s (+1.8%) 2.203s 10 1.08x

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

workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Express 10.542s (~) 11.024s (~) 0.482s 3 1.00x
🐘 Postgres Express 10.548s (~) 11.017s (~) 0.469s 3 1.00x
💻 Local Nitro 10.557s (~) 11.022s (~) 0.464s 3 1.00x
🐘 Postgres Nitro 10.566s (~) 11.019s (~) 0.453s 3 1.00x
🐘 Postgres Next.js (Turbopack) 11.040s (+0.9%) 11.352s (~) 0.312s 3 1.05x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 13.665s (-3.4%) 16.080s (+3.3%) 2.415s 2 1.00x
▲ Vercel Next.js (Turbopack) 13.802s (-9.7% 🟢) 16.052s (-7.6% 🟢) 2.250s 2 1.01x
▲ Vercel Nitro 13.813s (-44.3% 🟢) 15.353s (-41.2% 🟢) 1.541s 2 1.01x

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

workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 13.794s (-0.6%) 14.022s (-1.4%) 0.228s 5 1.00x
💻 Local Express 13.826s (~) 14.028s (~) 0.202s 5 1.00x
🐘 Postgres Express 13.828s (~) 14.017s (~) 0.189s 5 1.00x
💻 Local Nitro 13.829s (~) 14.027s (~) 0.199s 5 1.00x
🐘 Postgres Next.js (Turbopack) 14.545s (-1.5%) 15.018s (-1.7%) 0.473s 4 1.05x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 20.359s (-3.4%) 21.840s (-4.9%) 1.481s 3 1.00x
▲ Vercel Express 20.676s (-8.2% 🟢) 23.105s (-5.3% 🟢) 2.429s 3 1.02x
▲ Vercel Next.js (Turbopack) 21.225s (+1.8%) 23.531s (+3.4%) 2.306s 3 1.04x

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

workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Nitro 12.563s (~) 13.025s (~) 0.462s 7 1.00x
🐘 Postgres Express 12.580s (+1.0%) 13.021s (~) 0.441s 7 1.00x
💻 Local Express 12.589s (+0.9%) 13.025s (~) 0.436s 7 1.00x
🐘 Postgres Nitro 12.622s (+0.8%) 13.018s (~) 0.396s 7 1.00x
🐘 Postgres Next.js (Turbopack) 13.853s (~) 14.159s (-1.0%) 0.306s 7 1.10x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 27.709s (-7.7% 🟢) 29.712s (-8.0% 🟢) 2.004s 4 1.00x
▲ Vercel Express 29.823s (-21.8% 🟢) 33.087s (-16.4% 🟢) 3.264s 3 1.08x
▲ Vercel Next.js (Turbopack) 307.309s (+910.6% 🔺) 309.582s (+851.2% 🔺) 2.273s 1 11.09x

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

Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Nitro 1.197s (+0.6%) 2.006s (~) 0.809s 15 1.00x
🐘 Postgres Express 1.214s (+0.6%) 2.007s (~) 0.793s 15 1.01x
🐘 Postgres Nitro 1.266s (+4.9%) 2.074s (+3.2%) 0.808s 15 1.06x
💻 Local Express 1.271s (+3.1%) 2.007s (~) 0.736s 15 1.06x
🐘 Postgres Next.js (Turbopack) 1.282s (+0.7%) 2.007s (~) 0.725s 15 1.07x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.387s (-10.2% 🟢) 4.027s (-8.0% 🟢) 1.639s 8 1.00x
▲ Vercel Express 2.881s (-36.9% 🟢) 4.523s (-24.8% 🟢) 1.642s 7 1.21x
▲ Vercel Nitro 3.198s (+31.3% 🔺) 4.558s (+12.7% 🔺) 1.361s 7 1.34x

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

Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.430s (+3.3%) 2.591s (+8.3% 🔺) 1.162s 12 1.00x
🐘 Postgres Express 1.450s (+6.7% 🔺) 2.223s (-7.1% 🟢) 0.773s 14 1.01x
🐘 Postgres Next.js (Turbopack) 1.668s (+6.0% 🔺) 2.593s (+13.1% 🔺) 0.925s 12 1.17x
💻 Local Express 1.983s (+22.1% 🔺) 2.315s (+15.4% 🔺) 0.332s 13 1.39x
💻 Local Nitro 1.989s (+1.4%) 2.393s (+3.3%) 0.404s 13 1.39x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.673s (-13.9% 🟢) 4.336s (-16.3% 🟢) 1.662s 7 1.00x
▲ Vercel Express 3.332s (-7.4% 🟢) 5.114s (~) 1.782s 6 1.25x
▲ Vercel Nitro 4.058s (+12.8% 🔺) 5.709s (+4.8%) 1.651s 6 1.52x

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

Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.617s (~) 3.886s (-6.3% 🟢) 2.269s 8 1.00x
🐘 Postgres Express 1.879s (+18.7% 🔺) 4.138s (+3.1%) 2.259s 8 1.16x
🐘 Postgres Next.js (Turbopack) 4.026s (+22.9% 🔺) 4.586s (+14.2% 🔺) 0.560s 7 2.49x
💻 Local Express 5.673s (+33.9% 🔺) 6.213s (+31.5% 🔺) 0.540s 5 3.51x
💻 Local Nitro 5.872s (+6.7% 🔺) 6.414s (+6.7% 🔺) 0.543s 5 3.63x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 3.567s (-31.3% 🟢) 5.542s (-20.8% 🟢) 1.974s 6 1.00x
▲ Vercel Express 3.971s (-5.6% 🟢) 6.467s (+6.8% 🔺) 2.496s 5 1.11x
▲ Vercel Nitro 3.986s (-12.2% 🟢) 6.088s (-3.3%) 2.102s 5 1.12x

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

Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.201s (-1.3%) 2.007s (~) 0.806s 15 1.00x
🐘 Postgres Express 1.217s (+1.4%) 2.006s (~) 0.789s 15 1.01x
🐘 Postgres Next.js (Turbopack) 1.307s (+1.7%) 2.074s (+3.4%) 0.767s 15 1.09x
💻 Local Nitro 1.550s (-6.4% 🟢) 2.007s (~) 0.458s 15 1.29x
💻 Local Express 1.613s (+6.8% 🔺) 2.007s (~) 0.394s 15 1.34x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.339s (-20.5% 🟢) 3.678s (-24.4% 🟢) 1.338s 9 1.00x
▲ Vercel Next.js (Turbopack) 2.448s (-29.4% 🟢) 4.861s (-4.2%) 2.413s 7 1.05x
▲ Vercel Express 2.460s (+1.7%) 4.106s (-1.2%) 1.646s 8 1.05x

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

Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.375s (+1.7%) 2.394s (-7.6% 🟢) 1.018s 13 1.00x
🐘 Postgres Express 1.426s (+1.0%) 2.509s (+8.3% 🔺) 1.083s 12 1.04x
🐘 Postgres Next.js (Turbopack) 1.657s (+2.2%) 2.393s (+4.3%) 0.735s 13 1.20x
💻 Local Nitro 2.177s (+2.0%) 2.675s (+3.2%) 0.498s 12 1.58x
💻 Local Express 2.409s (+38.0% 🔺) 3.008s (+40.0% 🔺) 0.599s 10 1.75x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.627s (~) 4.730s (+16.8% 🔺) 2.103s 7 1.00x
▲ Vercel Next.js (Turbopack) 2.638s (+0.6%) 4.461s (+3.5%) 1.824s 7 1.00x
▲ Vercel Express 2.831s (-6.2% 🟢) 5.241s (+17.6% 🔺) 2.410s 6 1.08x

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

Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.555s (-3.5%) 3.885s (+3.3%) 2.331s 8 1.00x
🐘 Postgres Express 1.624s (+3.5%) 3.887s (-3.1%) 2.262s 8 1.04x
🐘 Postgres Next.js (Turbopack) 3.081s (+12.7% 🔺) 3.891s (+12.5% 🔺) 0.810s 8 1.98x
💻 Local Express 6.212s (+32.6% 🔺) 6.814s (+31.6% 🔺) 0.602s 5 4.00x
💻 Local Nitro 6.315s (+7.9% 🔺) 6.816s (+6.3% 🔺) 0.501s 5 4.06x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 3.644s (+3.1%) 5.806s (+6.9% 🔺) 2.162s 6 1.00x
▲ Vercel Express 3.741s (+8.2% 🔺) 5.909s (+15.6% 🔺) 2.169s 6 1.03x
▲ Vercel Nitro 4.274s (-4.4%) 5.873s (-2.5%) 1.599s 6 1.17x

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

workflow with 10 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.578s (~) 1.023s (~) 0.445s 59 1.00x
🐘 Postgres Express 0.590s (+4.9%) 1.006s (~) 0.415s 60 1.02x
💻 Local Express 0.625s (~) 1.005s (-1.6%) 0.380s 60 1.08x
💻 Local Nitro 0.655s (+4.3%) 1.022s (+1.7%) 0.367s 59 1.13x
🐘 Postgres Next.js (Turbopack) 0.831s (-2.0%) 1.006s (-5.0%) 0.175s 60 1.44x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 5.711s (+11.5% 🔺) 7.192s (+5.3% 🔺) 1.481s 9 1.00x
▲ Vercel Express 6.073s (+10.1% 🔺) 7.660s (+5.6% 🔺) 1.587s 8 1.06x
▲ Vercel Next.js (Turbopack) 6.209s (+1.3%) 8.125s (+4.3%) 1.916s 8 1.09x

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

workflow with 25 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.376s (+1.6%) 2.008s (-1.1%) 0.631s 45 1.00x
🐘 Postgres Nitro 1.416s (+4.6%) 2.029s (+1.1%) 0.613s 45 1.03x
💻 Local Express 1.568s (+5.0%) 2.007s (~) 0.438s 45 1.14x
💻 Local Nitro 1.603s (+2.8%) 2.029s (+1.1%) 0.426s 45 1.16x
🐘 Postgres Next.js (Turbopack) 1.992s (~) 2.315s (-3.6%) 0.323s 39 1.45x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 14.259s (-2.0%) 16.010s (-2.6%) 1.750s 6 1.00x
▲ Vercel Next.js (Turbopack) 14.336s (-12.8% 🟢) 16.697s (-9.9% 🟢) 2.360s 6 1.01x
▲ Vercel Express 14.835s (-3.0%) 16.862s (-2.4%) 2.028s 6 1.04x

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

workflow with 50 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.780s (+3.0%) 3.162s (+2.5%) 0.382s 39 1.00x
🐘 Postgres Express 2.787s (+2.4%) 3.136s (+0.8%) 0.350s 39 1.00x
💻 Local Express 3.392s (+6.4% 🔺) 4.010s (+0.8%) 0.617s 30 1.22x
💻 Local Nitro 3.472s (+2.9%) 4.043s (+0.8%) 0.571s 30 1.25x
🐘 Postgres Next.js (Turbopack) 3.907s (+1.3%) 4.182s (+3.4%) 0.276s 29 1.41x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 28.314s (-5.0%) 30.448s (-4.7%) 2.134s 4 1.00x
▲ Vercel Express 29.030s (+9.1% 🔺) 31.576s (+10.7% 🔺) 2.545s 4 1.03x
▲ Vercel Nitro 29.901s (+10.8% 🔺) 31.944s (+10.4% 🔺) 2.043s 4 1.06x

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

workflow with 10 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 0.255s (+4.6%) 1.023s (+1.6%) 0.768s 59 1.00x
🐘 Postgres Nitro 0.257s (+6.2% 🔺) 1.006s (~) 0.749s 60 1.01x
🐘 Postgres Next.js (Turbopack) 0.308s (+4.3%) 1.006s (~) 0.698s 60 1.21x
💻 Local Express 0.433s (+9.1% 🔺) 1.005s (~) 0.572s 60 1.70x
💻 Local Nitro 0.512s (+23.3% 🔺) 1.022s (+1.8%) 0.510s 59 2.01x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.196s (+17.1% 🔺) 3.696s (+1.5%) 1.500s 17 1.00x
▲ Vercel Express 2.234s (+9.0% 🔺) 4.388s (+15.2% 🔺) 2.154s 14 1.02x
▲ Vercel Next.js (Turbopack) 2.672s (+31.5% 🔺) 4.819s (+23.1% 🔺) 2.147s 13 1.22x

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

workflow with 25 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 0.414s (+3.8%) 1.029s (+1.1%) 0.615s 88 1.00x
🐘 Postgres Nitro 0.421s (+4.4%) 1.029s (+1.1%) 0.607s 88 1.02x
🐘 Postgres Next.js (Turbopack) 0.593s (-10.8% 🟢) 1.066s (-14.9% 🟢) 0.473s 85 1.43x
💻 Local Express 2.152s (+4.9%) 2.768s (+6.1% 🔺) 0.616s 33 5.20x
💻 Local Nitro 2.182s (~) 2.913s (+2.1%) 0.731s 31 5.27x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.837s (-0.6%) 4.558s (-8.6% 🟢) 1.720s 20 1.00x
▲ Vercel Express 2.878s (+10.6% 🔺) 4.698s (+13.8% 🔺) 1.820s 20 1.01x
▲ Vercel Next.js (Turbopack) 3.141s (-4.3%) 4.807s (-9.2% 🟢) 1.665s 19 1.11x

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

workflow with 50 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.810s (+3.2%) 1.351s (-4.1%) 0.541s 90 1.00x
🐘 Postgres Express 0.845s (+11.4% 🔺) 1.566s (+11.7% 🔺) 0.721s 77 1.04x
🐘 Postgres Next.js (Turbopack) 2.892s (-7.2% 🟢) 3.828s (-4.7%) 0.936s 32 3.57x
💻 Local Express 10.153s (+14.3% 🔺) 10.696s (+12.8% 🔺) 0.542s 12 12.53x
💻 Local Nitro 10.311s (+3.9%) 10.862s (+4.0%) 0.552s 12 12.73x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 6.037s (-1.8%) 7.538s (-4.5%) 1.501s 16 1.00x
▲ Vercel Express 7.258s (-7.6% 🟢) 9.002s (-5.2% 🟢) 1.745s 14 1.20x
▲ Vercel Next.js (Turbopack) 7.660s (-16.6% 🟢) 9.550s (-15.7% 🟢) 1.890s 13 1.27x

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

Stream Benchmarks (includes TTFB metrics)
workflow with stream

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.175s (~) 1.997s (~) 0.001s (+20.0% 🔺) 2.010s (~) 0.835s 10 1.00x
💻 Local Express 1.176s (+2.0%) 2.006s (~) 0.013s (+32.3% 🔺) 2.021s (~) 0.845s 10 1.00x
💻 Local Nitro 1.179s (~) 2.005s (~) 0.012s (-4.0%) 2.020s (~) 0.841s 10 1.00x
🐘 Postgres Express 1.197s (+3.1%) 1.993s (~) 0.001s (+44.4% 🔺) 2.010s (~) 0.814s 10 1.02x
🐘 Postgres Next.js (Turbopack) 1.236s (~) 2.002s (~) 0.001s (-23.1% 🟢) 2.011s (~) 0.775s 10 1.05x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.271s (+0.6%) 3.419s (-1.7%) 0.743s (-28.3% 🟢) 4.652s (-5.8% 🟢) 2.382s 10 1.00x
▲ Vercel Nitro 2.292s (-4.7%) 3.138s (-10.7% 🟢) 1.117s (-16.8% 🟢) 4.641s (-12.6% 🟢) 2.349s 10 1.01x
▲ Vercel Next.js (Turbopack) 3.228s (+42.4% 🔺) 4.865s (+33.9% 🔺) 0.808s (-10.3% 🟢) 6.287s (+24.2% 🔺) 3.058s 10 1.42x

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

stream pipeline with 5 transform steps (1MB)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.583s (+0.9%) 2.004s (~) 0.005s (-5.7% 🟢) 2.026s (~) 0.443s 30 1.00x
🐘 Postgres Nitro 1.585s (~) 2.004s (~) 0.005s (-5.7% 🟢) 2.026s (~) 0.440s 30 1.00x
💻 Local Express 1.609s (+2.0%) 2.011s (~) 0.012s (-0.5%) 2.026s (~) 0.417s 30 1.02x
💻 Local Nitro 1.628s (+1.8%) 2.011s (~) 0.014s (+9.9% 🔺) 2.027s (~) 0.399s 30 1.03x
🐘 Postgres Next.js (Turbopack) 1.791s (~) 2.042s (+1.6%) 0.005s (-8.4% 🟢) 2.059s (+1.6%) 0.268s 30 1.13x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 5.891s (-2.1%) 6.987s (-4.4%) 0.213s (-20.1% 🟢) 7.574s (-7.3% 🟢) 1.683s 8 1.00x
▲ Vercel Express 6.186s (-2.3%) 8.012s (+7.2% 🔺) 0.413s (-22.8% 🟢) 8.947s (+5.2% 🔺) 2.761s 7 1.05x
▲ Vercel Next.js (Turbopack) 7.019s (-11.6% 🟢) 8.376s (-10.4% 🟢) 0.267s (-22.8% 🟢) 9.185s (-11.3% 🟢) 2.165s 7 1.19x

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

10 parallel streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.789s (+6.0% 🔺) 1.030s (-1.5%) 0.000s (+194.8% 🔺) 1.062s (-0.6%) 0.273s 58 1.00x
🐘 Postgres Express 0.826s (+7.7% 🔺) 1.060s (+1.1%) 0.000s (+1.8%) 1.078s (+1.7%) 0.253s 56 1.05x
🐘 Postgres Next.js (Turbopack) 1.028s (-1.8%) 1.525s (~) 0.000s (+Infinity% 🔺) 1.544s (+0.7%) 0.516s 40 1.30x
💻 Local Express 1.475s (+6.5% 🔺) 2.014s (~) 0.000s (+100.0% 🔺) 2.016s (~) 0.541s 30 1.87x
💻 Local Nitro 1.479s (+4.1%) 2.013s (~) 0.000s (-50.0% 🟢) 2.016s (~) 0.537s 30 1.87x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.792s (-15.5% 🟢) 4.077s (-16.2% 🟢) 0.000s (-100.0% 🟢) 4.444s (-17.3% 🟢) 1.652s 14 1.00x
▲ Vercel Next.js (Turbopack) 2.963s (-31.6% 🟢) 4.942s (-14.8% 🟢) 0.000s (+Infinity% 🔺) 5.505s (-12.9% 🟢) 2.542s 11 1.06x
▲ Vercel Express 3.212s (+4.9%) 4.752s (+13.5% 🔺) 0.000s (+Infinity% 🔺) 5.204s (+12.4% 🔺) 1.992s 12 1.15x

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

fan-out fan-in 10 streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 1.569s (-4.9%) 2.097s (-2.0%) 0.000s (+Infinity% 🔺) 2.116s (-3.5%) 0.547s 29 1.00x
🐘 Postgres Nitro 1.634s (-5.3% 🟢) 2.136s (-5.3% 🟢) 0.000s (+Infinity% 🔺) 2.167s (-4.4%) 0.533s 28 1.04x
🐘 Postgres Next.js (Turbopack) 2.413s (+10.8% 🔺) 3.055s (+16.9% 🔺) 0.000s (+130.0% 🔺) 3.062s (+16.5% 🔺) 0.649s 20 1.54x
💻 Local Express 3.216s (+5.7% 🔺) 3.902s (+4.6%) 0.001s (-27.0% 🟢) 3.904s (+4.6%) 0.689s 16 2.05x
💻 Local Nitro 3.327s (+5.2% 🔺) 3.833s (~) 0.001s (+36.4% 🔺) 3.845s (~) 0.518s 16 2.12x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 4.583s (-30.4% 🟢) 6.199s (-25.5% 🟢) 0.000s (+Infinity% 🔺) 6.671s (-24.7% 🟢) 2.088s 9 1.00x
▲ Vercel Nitro 4.981s (-9.4% 🟢) 6.147s (-13.3% 🟢) 0.000s (+140.0% 🔺) 6.547s (-13.6% 🟢) 1.566s 10 1.09x
▲ Vercel Express 5.747s (-11.2% 🟢) 6.781s (-11.5% 🟢) 0.000s (-100.0% 🟢) 7.753s (-5.6% 🟢) 2.006s 8 1.25x

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

Summary

Fastest Framework by World

Winner determined by most benchmark wins

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

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 🐘 Postgres 16/21
Next.js (Turbopack) 🐘 Postgres 20/21
Nitro 🐘 Postgres 16/21
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)
  • 🌐 Redis: Community world (local development)
  • 🌐 Redis + BullMQ: Community world (local development)
  • 🌐 Cloudflare: Community world (local development)
  • 🌐 MySQL: Community world (local development)
  • 🌐 Azure: Community world (local development)
  • 🌐 NATS JetStream: Community world (local development)
  • 🌐 Upstash: Community world (local development)

📋 View full workflow run


Some benchmark jobs failed:

  • Local: failure
  • Postgres: success
  • Vercel: success

Check the workflow run for details.

The abortFromStep E2E flake had a second, dominant cause beyond the
suspension-gate race: a step that aborts a controller records the
durable hook_received event via an op that was flushed in the
*background* (safeWaitUntil), not awaited before step_completed. So the
workflow continuation enqueued by step_completed could run — resolving
Promise.all and dispatching a later step with the controller.signal —
before hook_received existed, serializing a stale aborted=false signal.

Add a preCompletionOps bucket to the step context for ops that must be
durable before the step's terminal event. Route the abort hook resume
there (keeping the real-time stream write in the background ops), and
await it before step_completed/step_failed in both the queue step
handler and the inline step executor. Combined with the pendingDeliveries
suspension-gate fix, the workflow continuation now both has the
hook_received in its log and waits for its hydration before serializing
downstream step arguments.

Co-Authored-By: Claude Fable 5 <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.

1 participant