n8n/packages/@n8n/engine
Veljko Terzic 75b94ccad5
perf(engine): Prefetch handler reads when a step message is published
Start the reads of a queue consumer when its message is published, so
the reads run while the message waits in the serial queue.

- step:settled: the step, the execution, the failed-step probe and the
  successor summaries. The reads start after the settlement commits.
- step:ready: the predecessor rows for the step inputs. The claim and the
  execution status read after the claim stay on the critical path.

A consumer that finds no prefetch does the same reads itself.

Ordering change: the settled handler can see an execution status that is
older by one queue wait. If a cancel lands in that window, one more step
can be planned. The ready handler cancels that step after its claim.
createSteps still checks for failed steps under the execution lock.
Planning reads still run after the settlement of the step commits, so
the last predecessor of a successor to settle sees the others settled.
No durability change.
2026-10-16 15:20:32 +02:00
..
docs/adr docs(engine): Add ADR on binary data access from a data plane in a separate process (no-changelog) (#40179) 2026-10-05 12:55:40 +00:00
src perf(engine): Prefetch handler reads when a step message is published 2026-10-16 15:20:32 +02:00
.dockerignore chore(core): Add @n8n/engine HTTP server and harness (no-changelog) (#29913) 2026-05-08 14:08:11 +00:00
.gitignore chore(core): Scaffold @n8n/engine package (no-changelog) (#29838) 2026-05-06 09:04:24 +00:00
AGENTS.md chore(engine): Use engine v2 naming (#39582) 2026-09-25 07:54:48 +00:00
eslint.config.mjs chore: Migrate database and engine lint to Oxlint (no-changelog) (#39841) 2026-09-29 12:24:22 +00:00
oxlint.config.mts chore: Migrate database and engine lint to Oxlint (no-changelog) (#39841) 2026-09-29 12:24:22 +00:00
package.json 🚀 Release 2.43.0 (#40376) 2026-10-06 07:10:16 +00:00
README.md chore(engine): Use engine v2 naming (#39582) 2026-09-25 07:54:48 +00:00
tsconfig.build.json chore: More Typescript 7 migrations (#34228) 2026-07-16 07:44:11 +00:00
tsconfig.json chore: More Typescript 7 migrations (#34228) 2026-07-16 07:44:11 +00:00
vitest.config.ts chore(core): Add @n8n/engine HTTP server and harness (no-changelog) (#29913) 2026-05-08 14:08:11 +00:00
vitest.integration.config.ts chore(core): Add @n8n/engine HTTP server and harness (no-changelog) (#29913) 2026-05-08 14:08:11 +00:00

@n8n/engine

n8n workflow execution engine (v2).

See the Engine v2 project for context. Public API and core interfaces are still being defined; the package is currently a scaffold and is not yet wired into n8n.

Dependencies

Be careful adding dependencies here. This package should not have runtime dependencies on other n8n components, only interfaces. If there is some functionality that should be shared, it should be factored into a common library.