shivaam opened a new pull request, #69079:
URL: https://github.com/apache/airflow/pull/69079
Adds TypeScript coordinator-mode execution on top of #67908.
This PR lets Airflow execute TypeScript task handlers through a bundled
Node.js entrypoint:
- Adds `airflow.sdk.coordinators.typescript.TypescriptCoordinator`, modeled
on the subprocess coordinator path.
- Adds the TypeScript coordinator runtime that speaks the supervisor
protocol over `--comm` and `--logs` sockets.
- Adds TaskClient-backed runtime support for Variables, XCom get/set, and
Connections.
- Adds `airflow-ts-pack`, which bundles a TypeScript entrypoint into
`bundle.mjs` and writes sibling `airflow-metadata.yaml` with the SDK supervisor
schema version.
- Documents Python stub Dag + TypeScript handler usage, bundle layout, and
Airflow coordinator configuration.
This is intentionally still Python-stub-Dag mode. TypeScript Dag declaration
is not introduced here; TypeScript registers handlers for Dag/task IDs declared
by Python stub tasks.
Stacking note: this PR is stacked on #67908. Once #67908 lands, I will
rebase this branch onto `main` so the diff only shows the coordinator/runtime
changes.
Testing performed:
- TypeScript SDK package checks: format, lint, typecheck, test, build,
format check.
- TypeScript SDK root prek hook: `ts-sdk-lint`.
- Python coordinator unit tests:
`task-sdk/tests/task_sdk/coordinators/typescript/test_coordinator.py`.
- Built-package import smoke test for root, coordinator, and bundle subpath
exports.
- Full daemon-mode E2E from this worktree without Breeze/Docker:
- Built SDK and `airflow-ts-pack` bundle.
- Bootstrapped isolated `AIRFLOW_HOME`.
- Ran Airflow `api-server`, `dag-processor`, and `scheduler`.
- Verified `hello_typescript`, `polyglot`, `connection_test`, and
`api_showcase` task runs reached success.
- Verified signal handling Dags: one SIGTERM task attempt reached failed,
and one retryable SIGTERM task retried then reached success with
`ctx.signal.aborted` markers.
---
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Codex (GPT-5)
Generated-by: Codex (GPT-5) following [the
guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]