Files
Eric Allam 5ba8557a51 chore(webapp,core): remove the end-of-life v3 (engine V1) execution stack (#4236)
## Summary

v3 (the engine that ran the SDK v3 era, internally
`RunEngineVersion.V1`) is end-of-life. Following the removal of the v3
execution apps
([#4194](https://github.com/triggerdotdev/trigger.dev/pull/4194)) and
the legacy dev websocket
([#4198](https://github.com/triggerdotdev/trigger.dev/pull/4198)), this
removes the remaining v3 execution stack from the server.

Clients still on v3 (an old SDK or CLI that has not upgraded) keep
getting a clear "upgrade to v4" response. Triggers, batch triggers,
reschedules, and deploys that resolve to v3 are rejected with a graceful
4xx pointing at the migration guide, never a 5xx, so a stale client
cannot affect server health. Self-hosted instances still running v3
should stay on the 4.5.x release line until they migrate.

## What is removed

- The MarQS queue and its shared/dev queue consumers.
- The v3 socket.io namespaces (coordinator, provider, shared-queue) and
the v3 run lifecycle services (attempt, checkpoint, and batch-resume).
- The graphile-worker background job system; all live jobs already run
on `@trigger.dev/redis-worker`.
- The `DEPRECATE_V3_ENABLED` flag: v3 is now rejected unconditionally,
so the flag is gone.
- Unused v3 exports from `@trigger.dev/core` (the `v3/zodNamespace`
subpath and the legacy socket message catalogs) and the now-dead MarQS
environment variables.

## What stays

The v4 engine is untouched. The graceful v3 rejection boundary stays,
`determineEngineVersion` still detects a v3 project so it can reject it,
and the batch service plus batch-completion worker stay for current
clients. Live queue concurrency limits and metrics now read from the v4
run engine instead of MarQS, and a brand-new dev environment now
defaults to v4.



## Dependency cleanup

Removes webapp dependencies left unused by this change: `seedrandom` and
`semver` (only the removed v3 code used them) plus a set that was
already dead, their orphaned `@types` packages, and two dead files. Adds
a `knip:deps` script and a `knip.json` config so unused dependencies can
be found the same way going forward.
2026-07-13 11:32:06 +01:00

3.1 KiB

Repo Overview

This is a pnpm 10.33.2 monorepo that uses turborepo @turbo.json. The following workspaces are relevant

Apps

  • /apps/webapp is a remix app that is the main API and dashboard for trigger.dev
  • /apps/supervisor is a node.js app that handles the execution of built tasks, interaction with the webapp through internal "engine" APIs, as well as interfacing with things like docker or kubernetes, to execute the code.

Public Packages

  • /packages/trigger-sdk is the @trigger.dev/sdk main SDK package.
  • /packages/cli-v3 is the trigger.dev CLI package. See our CLI dev command and Deployment docs for more information.
  • /packages/core is the @trigger.dev/core package that is shared across the SDK and other packages
  • /packages/build defines the types and prebuilt build extensions for trigger.dev. See our build extensions docs for more information.
  • /packages/react-hooks defines some useful react hooks like our realtime hooks. See our Realtime hooks and our Trigger hooks for more information.
  • /packages/redis-worker is the @trigger.dev/redis-worker package that implements a custom background job/worker sytem powered by redis for offloading work to the background, used in the webapp and also in the Run Engine 2.0.

Internal Packages

  • /internal-packages/* are packages that are used internally only, not published, and usually they have a tsc build step and are used in the webapp
  • /internal-packages/database is the @trigger.dev/database package that exports a prisma client, has the schema file, and exports a few other helpers.
  • /internal-packages/run-engine is the @internal/run-engine package that is "Run Engine 2.0" and handles moving a run all the way through it's lifecycle
  • /internal-packages/redis is the @internal/redis package that exports Redis types and the createRedisClient function to unify how we create redis clients in the repo. It's not used everywhere yet, but it's the preferred way to create redis clients from now on.
  • /internal-packages/testcontainers is the @internal/testcontainers package that exports a few useful functions for spinning up local testcontainers when writing vitest tests. See our tests.md file for more information.

References

  • /references/* are test workspaces that we use to write and test the system. Not quite e2e tests or automated, but just a useful place to help develop new features

Other

  • /docs is our trigger.dev/docs mintlify documentation site
  • /docker/Dockerfile is the one that creates the main trigger.dev published image
  • /docker/docker-compose.yml is the file we run locally to start postgresql, redis, and electric when we are doing local development. You can run it with pnpm run docker
  • /CONTRIBUTING.md defines the steps it takes for OSS contributors to start contributing.