Skip to content

[web] Probe deployment specVersion before replaying run#1782

Closed
VaguelySerious wants to merge 1 commit into
mainfrom
peter/replay-specversion-probe
Closed

[web] Probe deployment specVersion before replaying run#1782
VaguelySerious wants to merge 1 commit into
mainfrom
peter/replay-specversion-probe

Conversation

@VaguelySerious
Copy link
Copy Markdown
Member

Summary

Follows #1629 and #1627. The web dashboard's Replay / Re-run flow now probes the target deployment's specVersion via health check before calling recreateRunFromExisting, so the correct queue transport (JSON for old deployments, CBOR for new) is used.

Without this, the transport was chosen based on the original run's specVersion, which mismatches the target deployment when the deployment has been upgraded past that spec.

  • Resolves the deployment ID (override, or the run's current deployment) and sends a healthCheck(world, 'workflow', { deploymentId, timeout: 10_000 })
  • On healthy response with specVersion, passes it to recreateRunFromExisting
  • On probe failure (e.g. old deployment without health check support), falls back to the run's specVersion inside recreateRunFromExisting

Test plan

  • e2e: replay a specVersion 2 run → probe reports specVersion 2 → JSON transport used
  • e2e: replay against a deployment upgraded to specVersion 3 → probe reports 3 → CBOR transport used
  • e2e: probe timeout / old deployment without health check → falls back to run's specVersion

🤖 Generated with Claude Code

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Apr 16, 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 Apr 16, 2026 9:19pm
example-nextjs-workflow-webpack Ready Ready Preview, Comment Apr 16, 2026 9:19pm
example-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-astro-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-express-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-fastify-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-hono-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-nitro-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-nuxt-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-sveltekit-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workbench-vite-workflow Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workflow-docs Ready Ready Preview, Comment, Open in v0 Apr 16, 2026 9:19pm
workflow-swc-playground Ready Ready Preview, Comment Apr 16, 2026 9:19pm
workflow-web Ready Ready Preview, Comment Apr 16, 2026 9:19pm

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 16, 2026

🦋 Changeset detected

Latest commit: d568c54

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

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

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
❌ ▲ Vercel Production 922 1 67 990
✅ 💻 Local Development 994 0 86 1080
✅ 📦 Local Production 994 0 86 1080
✅ 🐘 Local Postgres 994 0 86 1080
✅ 🪟 Windows 90 0 0 90
❌ 🌍 Community Worlds 133 98 0 231
✅ 📋 Other 252 0 18 270
Total 4379 99 343 4821

❌ Failed Tests

▲ Vercel Production (1 failed)

express (1 failed):

  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep | wrun_01KPC31K8CRGAMRTG2DTKH1YMA | 🔍 observability
🌍 Community Worlds (98 failed)

mongodb (15 failed):

  • readableStreamWorkflow | wrun_01KPC2H3WE6BEQK0NTH05FBNHT
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KPC2HWCW4Q09ZP7S3Q5ZRAJH
  • webhookWorkflow | wrun_01KPC2J53M1BPED7K3HR4Z6P22
  • outputStreamWorkflow no startIndex (reads all chunks)
  • outputStreamWorkflow positive startIndex (skips first chunk)
  • outputStreamWorkflow negative startIndex (reads from end)
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns correct index after stream completes
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns -1 before any chunks are written
  • outputStreamWorkflow - getTailIndex and getChunks getChunks returns same content as reading the stream
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions | wrun_01KPC2PFJ9ZXRMVQQ8HK9B9PJQ
  • fetchWorkflow | wrun_01KPC2PX4HDDFAMX9QPJ40E8X1
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KPC2VE21TXT4CH860AHGX1E2
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • health check (CLI) - workflow health command reports healthy endpoints
  • resilient start: addTenWorkflow completes when run_created returns 500 | wrun_01KPC333W8R9FQH8QSZMGVEBN5

redis (15 failed):

  • readableStreamWorkflow | wrun_01KPC2H3WE6BEQK0NTH05FBNHT
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KPC2HWCW4Q09ZP7S3Q5ZRAJH
  • webhookWorkflow | wrun_01KPC2J53M1BPED7K3HR4Z6P22
  • outputStreamWorkflow no startIndex (reads all chunks)
  • outputStreamWorkflow positive startIndex (skips first chunk)
  • outputStreamWorkflow negative startIndex (reads from end)
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns correct index after stream completes
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns -1 before any chunks are written
  • outputStreamWorkflow - getTailIndex and getChunks getChunks returns same content as reading the stream
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions | wrun_01KPC2PFJ9ZXRMVQQ8HK9B9PJQ
  • fetchWorkflow | wrun_01KPC2PX4HDDFAMX9QPJ40E8X1
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KPC2VE21TXT4CH860AHGX1E2
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • health check (CLI) - workflow health command reports healthy endpoints
  • resilient start: addTenWorkflow completes when run_created returns 500 | wrun_01KPC333W8R9FQH8QSZMGVEBN5

turso (68 failed):

  • addTenWorkflow | wrun_01KPC2GEYGD67W80HF8QGTWRRA
  • addTenWorkflow | wrun_01KPC2GEYGD67W80HF8QGTWRRA
  • wellKnownAgentWorkflow (.well-known/agent) | wrun_01KPC2GRM2CQ3FBKRRDYNVPE7H
  • should work with react rendering in step
  • promiseAllWorkflow | wrun_01KPC2GSK8KD8BJTFSG9DBDBF7
  • promiseRaceWorkflow | wrun_01KPC2GZ7DX5J19GNDV5SFFVF3
  • promiseAnyWorkflow | wrun_01KPC2H1CSQ1WPKX4M402KSWX1
  • importedStepOnlyWorkflow | wrun_01KPC2H3KACW1XRGMD8R96EF26
  • readableStreamWorkflow | wrun_01KPC2H3WE6BEQK0NTH05FBNHT
  • hookWorkflow | wrun_01KPC2HEP0HJCR982ZWBS02BHC
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KPC2HWCW4Q09ZP7S3Q5ZRAJH
  • webhookWorkflow | wrun_01KPC2J53M1BPED7K3HR4Z6P22
  • sleepingWorkflow | wrun_01KPC2JBDK2AQ2RQJW40JWVYKN
  • parallelSleepWorkflow | wrun_01KPC2JQTTFG1D2BJQE7YY4YXT
  • nullByteWorkflow | wrun_01KPC2JYJVXTM9C0G05YTZWB41
  • workflowAndStepMetadataWorkflow | wrun_01KPC2K0RJ16MGBHRGNMTMMJSY
  • outputStreamWorkflow no startIndex (reads all chunks)
  • outputStreamWorkflow positive startIndex (skips first chunk)
  • outputStreamWorkflow negative startIndex (reads from end)
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns correct index after stream completes
  • outputStreamWorkflow - getTailIndex and getChunks getTailIndex returns -1 before any chunks are written
  • outputStreamWorkflow - getTailIndex and getChunks getChunks returns same content as reading the stream
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions | wrun_01KPC2PFJ9ZXRMVQQ8HK9B9PJQ
  • fetchWorkflow | wrun_01KPC2PX4HDDFAMX9QPJ40E8X1
  • promiseRaceStressTestWorkflow | wrun_01KPC2Q0N8KG9A4W19KD7W9EEY
  • 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 catchability FatalError can be caught and detected with FatalError.is()
  • error handling not registered WorkflowNotRegisteredError fails the run when workflow does not exist
  • error handling not registered StepNotRegisteredError fails the step but workflow can catch it
  • error handling not registered StepNotRegisteredError fails the run when not caught in workflow
  • hookCleanupTestWorkflow - hook token reuse after workflow completion | wrun_01KPC2TREW9ND7N4VGHDR2BZ4Y
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KPC2VE21TXT4CH860AHGX1E2
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_01KPC2W6GEZ549P819QKGT5ZYR
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) | wrun_01KPC2WW1TQBCMWX52WZS66390
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument | wrun_01KPC2XA9BH0AQPDPDWAVJYZSB
  • closureVariableWorkflow - nested step functions with closure variables | wrun_01KPC2XHB9FYMY73MTAXXWE2K6
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step | wrun_01KPC2XM4ZMGGKEWWF6Q8C5GT2
  • runClassSerializationWorkflow - Run instances serialize across workflow/step boundaries | wrun_01KPC2Y0CRA22T30TWYQA12H6G
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • health check (CLI) - workflow health command reports healthy endpoints
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly | wrun_01KPC2YJFNNPJG0EE701XB4CK8
  • Calculator.calculate - static workflow method using static step methods from another class | wrun_01KPC2YSBG2RYFXT1VX41VHGEQ
  • AllInOneService.processNumber - static workflow method using sibling static step methods | wrun_01KPC2Z1T2VWMT46K048V4QT3X
  • ChainableService.processWithThis - static step methods using this to reference the class | wrun_01KPC2Z8CH6NB3DYEEJBQ7Y6AK
  • thisSerializationWorkflow - step function invoked with .call() and .apply() | wrun_01KPC2ZG046VGCRSJ6Y7P5A35D
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE | wrun_01KPC2ZQWB3EEMMZWDV8RE8YM9
  • instanceMethodStepWorkflow - instance methods with "use step" directive | wrun_01KPC2ZZ557V0706WTGTD97N7E
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context | wrun_01KPC30B5QHM12944PDS4RECFH
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument | wrun_01KPC30KH345Z46M2QDMTG7AXD
  • cancelRun - cancelling a running workflow | wrun_01KPC30V8V1MP61282X4G54CH9
  • cancelRun via CLI - cancelling a running workflow | wrun_01KPC315WECENKVV6NWC13NZR7
  • pages router addTenWorkflow via pages router
  • pages router promiseAllWorkflow via pages router
  • pages router sleepingWorkflow via pages router
  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep | wrun_01KPC31K8CRGAMRTG2DTKH1YMA
  • sleepInLoopWorkflow - sleep inside loop with steps actually delays each iteration | wrun_01KPC32BTQE1J1QJMKYM00XM0H
  • sleepWithSequentialStepsWorkflow - sequential steps work with concurrent sleep (control) | wrun_01KPC32P8GMA5RDHHN3VF19ZBZ
  • importMetaUrlWorkflow - import.meta.url is available in step bundles | wrun_01KPC32XK5SCPB3RES4CEP3TVE
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) | wrun_01KPC331FX0P43BE6ERVSQZ70B
  • resilient start: addTenWorkflow completes when run_created returns 500 | wrun_01KPC333W8R9FQH8QSZMGVEBN5
  • getterStepWorkflow - getter functions with "use step" directive | wrun_01KPC3390229FKD14WSSM6TBKY

Details by Category

❌ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 83 0 7
✅ example 83 0 7
❌ express 82 1 7
✅ fastify 83 0 7
✅ hono 83 0 7
✅ nextjs-turbopack 88 0 2
✅ nextjs-webpack 88 0 2
✅ nitro 83 0 7
✅ nuxt 83 0 7
✅ sveltekit 83 0 7
✅ vite 83 0 7
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 84 0 6
✅ express-stable 84 0 6
✅ fastify-stable 84 0 6
✅ hono-stable 84 0 6
✅ nextjs-turbopack-canary 71 0 19
✅ nextjs-turbopack-stable 90 0 0
✅ nextjs-webpack-canary 71 0 19
✅ nextjs-webpack-stable 90 0 0
✅ nitro-stable 84 0 6
✅ nuxt-stable 84 0 6
✅ sveltekit-stable 84 0 6
✅ vite-stable 84 0 6
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 84 0 6
✅ express-stable 84 0 6
✅ fastify-stable 84 0 6
✅ hono-stable 84 0 6
✅ nextjs-turbopack-canary 71 0 19
✅ nextjs-turbopack-stable 90 0 0
✅ nextjs-webpack-canary 71 0 19
✅ nextjs-webpack-stable 90 0 0
✅ nitro-stable 84 0 6
✅ nuxt-stable 84 0 6
✅ sveltekit-stable 84 0 6
✅ vite-stable 84 0 6
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 84 0 6
✅ express-stable 84 0 6
✅ fastify-stable 84 0 6
✅ hono-stable 84 0 6
✅ nextjs-turbopack-canary 71 0 19
✅ nextjs-turbopack-stable 90 0 0
✅ nextjs-webpack-canary 71 0 19
✅ nextjs-webpack-stable 90 0 0
✅ nitro-stable 84 0 6
✅ nuxt-stable 84 0 6
✅ sveltekit-stable 84 0 6
✅ vite-stable 84 0 6
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 90 0 0
❌ 🌍 Community Worlds
App Passed Failed Skipped
✅ mongodb-dev 6 0 0
❌ mongodb 56 15 0
✅ redis-dev 6 0 0
❌ redis 56 15 0
✅ turso-dev 6 0 0
❌ turso 3 68 0
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 84 0 6
✅ e2e-local-postgres-nest-stable 84 0 6
✅ e2e-local-prod-nest-stable 84 0 6

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: failure
  • Local Dev: success
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 16, 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.032s (-27.8% 🟢) 1.004s (~) 0.972s 10 1.00x
💻 Local Nitro 0.044s (+2.3%) 1.005s (~) 0.961s 10 1.38x
🐘 Postgres Nitro 0.044s (-53.3% 🟢) 1.009s (-3.3%) 0.965s 10 1.39x
🐘 Postgres Express 0.055s (-5.0%) 1.017s (+0.6%) 0.962s 10 1.72x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 0.286s (+13.6% 🔺) 1.977s (-15.3% 🟢) 1.692s 10 1.00x
▲ Vercel Express 0.288s (+22.4% 🔺) 2.164s (+1.3%) 1.876s 10 1.01x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.109s (-2.7%) 2.010s (~) 0.901s 10 1.00x
🐘 Postgres Express 1.110s (-3.2%) 2.010s (~) 0.900s 10 1.00x
💻 Local Express 1.115s (-0.9%) 2.005s (~) 0.889s 10 1.01x
💻 Local Nitro 1.134s (~) 2.006s (~) 0.872s 10 1.02x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.210s (+17.9% 🔺) 3.959s (+4.0%) 1.749s 10 1.00x
▲ Vercel Next.js (Turbopack) 2.637s (+29.6% 🔺) 4.420s (+15.4% 🔺) 1.783s 10 1.19x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 10.645s (-2.1%) 11.020s (~) 0.375s 3 1.00x
🐘 Postgres Express 10.700s (-2.4%) 11.023s (~) 0.323s 3 1.01x
💻 Local Express 10.755s (-1.5%) 11.021s (~) 0.266s 3 1.01x
💻 Local Nitro 10.945s (~) 11.023s (~) 0.079s 3 1.03x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 17.095s (+0.7%) 18.653s (-6.8% 🟢) 1.558s 2 1.00x
▲ Vercel Next.js (Turbopack) 17.603s (+1.6%) 19.251s (-0.8%) 1.648s 2 1.03x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 13.946s (-4.4%) 14.022s (-6.7% 🟢) 0.076s 5 1.00x
🐘 Postgres Express 14.078s (-3.5%) 15.023s (~) 0.945s 4 1.01x
💻 Local Express 14.473s (-3.3%) 15.026s (~) 0.553s 4 1.04x
💻 Local Nitro 14.979s (-0.5%) 15.280s (-4.7%) 0.301s 4 1.07x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 32.678s (-37.8% 🟢) 34.558s (-36.7% 🟢) 1.880s 2 1.00x
▲ Vercel Express 35.681s (-29.1% 🟢) 37.389s (-28.9% 🟢) 1.707s 2 1.09x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 13.006s (-7.1% 🟢) 13.450s (-7.8% 🟢) 0.444s 7 1.00x
🐘 Postgres Nitro 13.033s (-6.7% 🟢) 13.447s (-6.0% 🟢) 0.414s 7 1.00x
💻 Local Express 15.113s (-9.0% 🟢) 16.027s (-5.9% 🟢) 0.914s 6 1.16x
💻 Local Nitro 16.404s (-2.3%) 17.031s (~) 0.627s 6 1.26x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 129.968s (+7.2% 🔺) 132.646s (+7.3% 🔺) 2.678s 2 1.00x
▲ Vercel Next.js (Turbopack) 137.757s (-65.0% 🟢) 142.340s (-64.0% 🟢) 4.583s 2 1.06x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.197s (-6.1% 🟢) 2.008s (~) 0.811s 15 1.00x
🐘 Postgres Express 1.197s (-5.0% 🟢) 2.008s (~) 0.811s 15 1.00x
💻 Local Express 1.394s (-6.4% 🟢) 2.004s (~) 0.611s 15 1.16x
💻 Local Nitro 1.484s (-9.0% 🟢) 2.005s (-3.3%) 0.521s 15 1.24x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.679s (-6.3% 🟢) 4.585s (-0.8%) 1.907s 7 1.00x
▲ Vercel Next.js (Turbopack) 5.891s (+73.4% 🔺) 8.026s (+62.7% 🔺) 2.135s 4 2.20x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.260s (-3.9%) 3.009s (~) 0.749s 10 1.00x
🐘 Postgres Express 2.288s (-3.1%) 3.010s (~) 0.721s 10 1.01x
💻 Local Express 2.367s (-19.8% 🟢) 3.007s (-12.9% 🟢) 0.640s 10 1.05x
💻 Local Nitro 2.823s (-10.2% 🟢) 3.008s (-22.6% 🟢) 0.185s 10 1.25x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.916s (-58.9% 🟢) 5.185s (-41.8% 🟢) 2.269s 6 1.00x
▲ Vercel Express 3.653s (+0.9%) 5.456s (+6.8% 🔺) 1.803s 6 1.25x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 3.360s (-3.6%) 4.009s (~) 0.650s 8 1.00x
🐘 Postgres Nitro 3.362s (-3.4%) 4.009s (~) 0.646s 8 1.00x
💻 Local Express 6.130s (-26.5% 🟢) 7.016s (-22.3% 🟢) 0.886s 5 1.82x
💻 Local Nitro 7.506s (-10.1% 🟢) 8.019s (-11.1% 🟢) 0.513s 4 2.23x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 5.183s (-41.9% 🟢) 6.817s (-37.8% 🟢) 1.634s 6 1.00x
▲ Vercel Express 6.105s (+44.0% 🔺) 8.281s (+35.1% 🔺) 2.176s 6 1.18x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.188s (-5.5% 🟢) 2.007s (~) 0.820s 15 1.00x
🐘 Postgres Express 1.197s (-4.8%) 2.007s (~) 0.810s 15 1.01x
💻 Local Express 1.418s (-25.1% 🟢) 2.005s (-15.2% 🟢) 0.587s 15 1.19x
💻 Local Nitro 1.538s (-17.6% 🟢) 2.006s (-14.3% 🟢) 0.468s 15 1.29x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.214s (-14.2% 🟢) 6.943s (+59.6% 🔺) 4.729s 8 1.00x
▲ Vercel Next.js (Turbopack) 11.942s (+307.3% 🔺) 14.181s (+205.5% 🔺) 2.240s 3 5.39x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.254s (-3.6%) 3.008s (~) 0.754s 10 1.00x
🐘 Postgres Express 2.274s (-2.9%) 3.010s (~) 0.736s 10 1.01x
💻 Local Express 2.635s (-15.9% 🟢) 3.108s (-17.4% 🟢) 0.473s 10 1.17x
💻 Local Nitro 2.812s (-8.3% 🟢) 3.110s (-20.0% 🟢) 0.298s 10 1.25x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 2.474s (-21.3% 🟢) 4.037s (-10.7% 🟢) 1.563s 8 1.00x
▲ Vercel Express 2.721s (-14.8% 🟢) 4.077s (-14.9% 🟢) 1.356s 8 1.10x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 3.398s (-2.9%) 4.009s (~) 0.611s 8 1.00x
🐘 Postgres Nitro 3.401s (-2.3%) 4.009s (~) 0.608s 8 1.00x
💻 Local Express 6.660s (-24.3% 🟢) 7.218s (-22.2% 🟢) 0.559s 5 1.96x
💻 Local Nitro 7.939s (-13.2% 🟢) 8.773s (-12.5% 🟢) 0.834s 4 2.34x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.723s (-42.0% 🟢) 5.433s (-33.6% 🟢) 1.710s 6 1.00x
▲ Vercel Next.js (Turbopack) 3.881s (-42.6% 🟢) 5.485s (-35.8% 🟢) 1.604s 6 1.04x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Express | Next.js (Turbopack)

workflow with 10 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.587s (-28.5% 🟢) 1.006s (~) 0.419s 60 1.00x
🐘 Postgres Express 0.596s (-29.0% 🟢) 1.006s (-1.7%) 0.410s 60 1.02x
💻 Local Express 0.840s (-14.7% 🟢) 1.056s (-1.8%) 0.217s 57 1.43x
💻 Local Nitro 1.020s (+4.0%) 1.823s (+66.7% 🔺) 0.804s 33 1.74x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 11.481s (-39.6% 🟢) 13.479s (-36.8% 🟢) 1.998s 5 1.00x
▲ Vercel Next.js (Turbopack) 12.980s (-10.5% 🟢) 14.827s (-7.8% 🟢) 1.847s 5 1.13x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: 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 🥇 Nitro 1.403s (-27.2% 🟢) 2.007s (-4.4%) 0.605s 45 1.00x
🐘 Postgres Express 1.431s (-27.6% 🟢) 2.008s (-11.1% 🟢) 0.577s 45 1.02x
💻 Local Express 2.490s (-17.4% 🟢) 3.007s (-16.1% 🟢) 0.517s 30 1.78x
💻 Local Nitro 3.050s (~) 3.729s (-0.8%) 0.680s 25 2.17x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 30.862s (-38.0% 🟢) 32.908s (-36.4% 🟢) 2.047s 3 1.00x
▲ Vercel Express 31.220s (-9.6% 🟢) 35.983s (-2.2%) 4.763s 3 1.01x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: 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.858s (-30.4% 🟢) 3.085s (-33.0% 🟢) 0.227s 39 1.00x
🐘 Postgres Express 2.974s (-25.5% 🟢) 3.306s (-24.3% 🟢) 0.332s 37 1.04x
💻 Local Express 7.687s (-16.5% 🟢) 8.147s (-18.7% 🟢) 0.460s 15 2.69x
💻 Local Nitro 8.962s (-3.6%) 9.324s (-6.9% 🟢) 0.363s 13 3.14x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 95.862s (-10.5% 🟢) 98.034s (-10.0% 🟢) 2.172s 2 1.00x
▲ Vercel Express 116.466s (-10.4% 🟢) 117.695s (-10.9% 🟢) 1.229s 2 1.21x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

workflow with 10 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.217s (-23.3% 🟢) 1.006s (~) 0.789s 60 1.00x
🐘 Postgres Express 0.225s (-20.2% 🟢) 1.007s (~) 0.781s 60 1.04x
💻 Local Express 0.513s (-8.5% 🟢) 1.004s (~) 0.491s 60 2.36x
💻 Local Nitro 0.573s (-5.3% 🟢) 1.004s (-1.7%) 0.432s 60 2.64x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 1.621s (-17.1% 🟢) 3.016s (-17.1% 🟢) 1.395s 20 1.00x
▲ Vercel Next.js (Turbopack) 1.779s (-12.0% 🟢) 3.388s (-10.7% 🟢) 1.609s 19 1.10x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: 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 🥇 Nitro 0.353s (-28.8% 🟢) 1.006s (~) 0.652s 90 1.00x
🐘 Postgres Express 0.367s (-28.1% 🟢) 1.006s (~) 0.639s 90 1.04x
💻 Local Express 2.051s (-18.4% 🟢) 2.771s (-7.9% 🟢) 0.721s 33 5.80x
💻 Local Nitro 2.377s (-6.4% 🟢) 3.008s (~) 0.632s 30 6.73x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 4.487s (+26.9% 🔺) 6.096s (+17.4% 🔺) 1.609s 17 1.00x
▲ Vercel Express 5.953s (+95.4% 🔺) 7.564s (+57.3% 🔺) 1.611s 12 1.33x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: Next.js (Turbopack) | Express

workflow with 50 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.562s (-28.9% 🟢) 1.006s (~) 0.445s 120 1.00x
🐘 Postgres Express 0.593s (-27.6% 🟢) 1.006s (-1.1%) 0.413s 120 1.06x
💻 Local Express 8.914s (-20.3% 🟢) 9.342s (-21.8% 🟢) 0.429s 13 15.87x
💻 Local Nitro 10.530s (-5.9% 🟢) 11.120s (-4.7%) 0.590s 11 18.75x
💻 Local Next.js (Turbopack) ⚠️ missing - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - -

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 7.620s (+2.7%) 9.027s (-2.4%) 1.407s 14 1.00x
▲ Vercel Next.js (Turbopack) 22.144s (+114.4% 🔺) 23.853s (+94.1% 🔺) 1.709s 14 2.91x
▲ Vercel Nitro ⚠️ missing - - - -

🔍 Observability: 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 0.155s (-24.5% 🟢) 0.999s (~) 0.001s (-20.0% 🟢) 1.010s (~) 0.855s 10 1.00x
🐘 Postgres Express 0.156s (-23.9% 🟢) 1.000s (~) 0.001s (-18.8% 🟢) 1.010s (~) 0.853s 10 1.01x
💻 Local Express 0.182s (-8.5% 🟢) 1.003s (~) 0.008s (-32.2% 🟢) 1.013s (~) 0.831s 10 1.18x
💻 Local Nitro 0.212s (-0.9%) 1.004s (~) 0.010s (-21.6% 🟢) 1.016s (~) 0.804s 10 1.37x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 1.665s (-75.7% 🟢) 3.358s (-61.2% 🟢) 1.370s (+116.8% 🔺) 5.462s (-44.2% 🟢) 3.797s 10 1.00x
▲ Vercel Express 2.375s (-5.2% 🟢) 3.600s (-12.0% 🟢) 1.146s (+19.3% 🔺) 5.265s (-5.8% 🟢) 2.890s 10 1.43x
▲ Vercel Nitro ⚠️ missing - - - - -

🔍 Observability: Next.js (Turbopack) | Express

stream pipeline with 5 transform steps (1MB)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.496s (-20.4% 🟢) 1.006s (~) 0.003s (-18.0% 🟢) 1.020s (~) 0.523s 59 1.00x
🐘 Postgres Express 0.509s (-19.3% 🟢) 1.007s (~) 0.004s (-5.8% 🟢) 1.021s (~) 0.512s 59 1.02x
💻 Local Express 0.651s (-14.0% 🟢) 1.011s (-1.8%) 0.013s (+35.2% 🔺) 1.025s (-1.4%) 0.374s 59 1.31x
💻 Local Nitro 0.767s (-8.5% 🟢) 1.013s (~) 0.009s (-6.7% 🟢) 1.023s (-8.3% 🟢) 0.256s 59 1.55x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 4.383s (-74.1% 🟢) 5.996s (-67.1% 🟢) 0.217s (+2.8%) 6.635s (-65.0% 🟢) 2.252s 10 1.00x
▲ Vercel Express 5.991s (-7.9% 🟢) 7.230s (-9.7% 🟢) 0.247s (-39.5% 🟢) 7.873s (-10.9% 🟢) 1.883s 8 1.37x
▲ Vercel Nitro ⚠️ missing - - - - -

🔍 Observability: Next.js (Turbopack) | Express

10 parallel streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.908s (-6.3% 🟢) 1.070s (-14.2% 🟢) 0.000s (+71.4% 🔺) 1.086s (-13.7% 🟢) 0.178s 56 1.00x
🐘 Postgres Express 0.912s (-5.1% 🟢) 1.034s (-19.1% 🟢) 0.000s (+19.0% 🔺) 1.042s (-20.3% 🟢) 0.130s 58 1.00x
💻 Local Express 1.036s (-15.4% 🟢) 1.682s (-16.7% 🟢) 0.000s (-41.7% 🟢) 1.684s (-16.7% 🟢) 0.648s 36 1.14x
💻 Local Nitro 1.242s (+1.5%) 2.022s (~) 0.000s (+33.3% 🔺) 2.024s (~) 0.783s 30 1.37x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 3.217s (-68.4% 🟢) 4.449s (-61.4% 🟢) 0.000s (NaN%) 4.958s (-58.9% 🟢) 1.741s 13 1.00x
▲ Vercel Express 3.727s (~) 4.831s (-5.3% 🟢) 0.000s (-100.0% 🟢) 5.195s (-6.1% 🟢) 1.468s 12 1.16x
▲ Vercel Nitro ⚠️ missing - - - - -

🔍 Observability: 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 🥇 Nitro 1.651s (-7.8% 🟢) 2.144s (~) 0.000s (-100.0% 🟢) 2.159s (-0.7%) 0.508s 28 1.00x
🐘 Postgres Express 1.698s (-4.2%) 2.033s (-6.6% 🟢) 0.000s (+Infinity% 🔺) 2.044s (-7.0% 🟢) 0.347s 30 1.03x
💻 Local Express 2.916s (-15.9% 🟢) 3.293s (-18.4% 🟢) 0.000s (-86.8% 🟢) 3.295s (-18.4% 🟢) 0.379s 19 1.77x
💻 Local Nitro 3.507s (+3.5%) 4.034s (~) 0.001s (+25.0% 🔺) 4.037s (~) 0.530s 15 2.12x
💻 Local Next.js (Turbopack) ⚠️ missing - - - - -
🐘 Postgres Next.js (Turbopack) ⚠️ missing - - - - -

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 4.222s (-8.0% 🟢) 5.302s (-12.0% 🟢) 0.000s (+Infinity% 🔺) 5.698s (-11.8% 🟢) 1.476s 11 1.00x
▲ Vercel Next.js (Turbopack) 4.476s (-20.3% 🟢) 5.804s (-16.9% 🟢) 0.000s (-20.0% 🟢) 6.227s (-17.4% 🟢) 1.752s 10 1.06x
▲ Vercel Nitro ⚠️ missing - - - - -

🔍 Observability: Express | Next.js (Turbopack)

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World 🥇 Fastest Framework Wins
💻 Local Express 21/21
🐘 Postgres Nitro 18/21
▲ Vercel Next.js (Turbopack) 11/21
Fastest World by Framework

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 🐘 Postgres 20/21
Next.js (Turbopack) ▲ Vercel 21/21
Nitro 🐘 Postgres 20/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)

📋 View full workflow run

Replay/Re-run now probes the target deployment's specVersion via health
check before calling recreateRunFromExisting. Without this, the queue
transport is chosen based on the original run's specVersion, which
mismatches the deployment when the deployment has been upgraded past
the run's specVersion.

Falls back to the run's specVersion if the health check fails
(e.g. against old deployments without health check support).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Signed-off-by: Peter Wielander <mittgfu@gmail.com>
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.

Review

Small, well-targeted fix. The logic is correct and the fallback preserves existing behavior when the probe fails, so this is strictly safer than the pre-PR behavior.

What looks good

  • Correctness: recreateRunFromExisting already supports the specVersion option (runs.ts:64-65), and healthCheck already returns specVersion on the HealthCheckResult. The PR just wires them together.
  • Deployment ID resolution matches the fallback in recreateRunFromExisting — uses the override if provided, else the run's current deploymentId. Both callers agree on the target.
  • Fallback on probe failure leaves specVersion as undefined, which falls back to the existing run.specVersion ?? SPEC_VERSION_LEGACY logic inside recreateRunFromExisting. No regression.
  • Changeset is scoped to @workflow/web only, since the only behavior change is in the web dashboard's replay action.

Non-blocking concerns

See inline comments. The main one worth discussing is the UX cost of the 10s probe timeout for replays against old deployments that don't support health check — that's arguably the most common case this PR is trying to help, and each one now pays up to 10s of wait before falling back.

Test plan

The PR description has an unchecked test plan. Ideally these e2e tests would be added before merge. At minimum the third case (probe timeout) is worth exercising since it's the new latency floor for the old-deployment case.

if (hc.healthy && hc.specVersion != null) {
specVersion = hc.specVersion;
}
} catch {
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.

Latency concern: this adds up to 10s of UI wait for the exact case the PR is trying to help.

The healthCheck() implementation polls for a response until timeout (helpers.ts:254-294). An old deployment that doesn't recognize the __wkf_workflow_health_check queue topic will silently drop the message — there's no fast-fail signal, so the probe will wait the full 10s before returning healthy: false.

This means: a user clicking "Replay" on a run from a pre-health-check deployment pays 10 seconds of UI latency before the replay even starts. That's the exact scenario the PR needs to handle gracefully (old deployment \u2192 JSON transport), but it's now the slowest case.

Options to consider:

  1. Shorter timeout (e.g. 3\u20134s) \u2014 if the deployment is alive and supports health check, it typically responds in < 500ms, so 10s is overkill. 3s should be safe.

  2. Version-gate the probe \u2014 only probe if run.specVersion suggests the deployment might have been upgraded. If run.specVersion >= SPEC_VERSION_SUPPORTS_HEALTH_CHECK, probe; otherwise skip. (Would need to add that constant.)

  3. Non-blocking probe with a short budget \u2014 race the probe against a short timeout (say 2s); if it doesn't resolve in time, fall back. The successful path stays fast, the failure path isn't punished.

Option 1 is the simplest and probably sufficient.

// if the probe fails (e.g. old deployment without health check support).
let specVersion: number | undefined;
try {
let targetDeploymentId = deploymentId;
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.

Nit: when deploymentId is not provided, this calls world.runs.get(runId) to get the run's deploymentId, and then recreateRunFromExisting internally calls world.runs.get(runId, { resolveData: 'all' }) again a moment later. Not a correctness issue, just a duplicated round-trip. Could be avoided by fetching the run once here and passing both run and the resolved ID through, but that would require a larger signature change on recreateRunFromExisting. Probably not worth it for a non-hot path.

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.

2 participants