# Kestra（软件）

**Kestra** 是一个开源、事件驱动的编排平台，面向数据、AI 与基础设施工作流，主要以 Java 编写，采用 Apache 2.0 许可证。工作流（称为流程）以声明式 YAML 定义，任务可运行任何语言的代码，包括 Python、Node.js、R、Go 和 Shell，通常打包在 Docker 容器镜像中。<sup>[1](https://kestra.io/docs/why-kestra)</sup><sup> • </sup><sup>[2](https://huggingface.co/kestra)</sup> 该项目由 Kestra Technologies 开发，定位为横跨数据管道、业务流程和 AI 智能体的工作流控制平面。<sup>[3](https://github.com/kestra-io/kestra)</sup>

| 关键事实 | 详情 |
|---|---|
| 是什么 | 开源、事件驱动的编排平台，面向数据、AI 与基础设施工作流<sup>[1](https://kestra.io/docs/why-kestra)</sup> |
| 许可证与语言 | Apache 2.0；主要以 Java 编写<sup>[4](https://appsgit.com/apps/kestra)</sup><sup> • </sup><sup>[5](https://kestra.io/blogs/kestra-2-0-almost-here)</sup> |
| 首次公开发布 | 2022 年 2 月 1 日，由吕多维克·德翁（Ludovic Dehon）宣布<sup>[6](https://kestra.io/blogs/2022-02-01-kestra-opensource)</sup> |
| 当前主要版本 | Kestra 2.0，2026 年 9 月 8 日正式可用，为 LTS 版本，修复补丁向后移植一年<sup>[7](https://kestra.io/blogs/release-2-0/index)</sup> |
| 工作流定义 | 声明式 YAML；每个流程需要 `id`、`namespace` 和 `tasks`<sup>[8](https://github.com/kestra-io/kestra/blob/develop/ui/src/assets/docs/basic.md)</sup> |
| 触发器类型 | 六种核心类型：Schedule、Flow、Webhook、Polling、Realtime 和 MCP Tool<sup>[9](https://kestra.io/docs/workflow-components/triggers)</sup> |
| 运行时要求 | Kestra 1.3 需要 Java 25 或更高版本（推荐 Eclipse Temurin）<sup>[10](https://kestra.io/docs/releases/index)</sup> |

## 历史

Kestra 最初是吕多维克·德翁（Ludovic Dehon，现任首席技术官兼联合创始人）的个人项目，源于他在欧洲大型 DIY 零售商[乐华梅兰](https://www.edgepedia.org/zh/leroy-merlin)（Leroy Merlin）使用 Airflow 时遇到的实际困难。第一个实现运行在 Kafka、Kafka Streams、[Elasticsearch](https://www.edgepedia.org/zh/elasticsearch) 和一个 GCS 存储桶之上，并于 2020 年在乐华梅兰投入生产使用。<sup>[11](https://kestra.io/blogs/kestra-2-0-engineering/index)</sup> 首次公开发布于 2022 年 2 月 1 日宣布，作为一个开源平台，用于大规模编排和调度工作流。<sup>[6](https://kestra.io/blogs/2022-02-01-kestra-opensource)</sup>

早期用户反馈称，部署 Kafka、Elasticsearch、存储桶和 Kestra 对大多数人来说过于复杂，因此项目增加了一个简单的数据库后端版本，团队认为这促进了开源版本的采用。<sup>[11](https://kestra.io/blogs/kestra-2-0-engineering/index)</sup>

## 架构

Kestra 的架构由六个服务器角色组成，每个角色既可以共享一个进程，也可以作为独立服务独立扩展：执行器（Executor）、工作器控制器（Worker Controller）、工作器（Worker）、调度器（Scheduler）、Web 服务器（Webserver）和索引器（Indexer）。每个角色都通过队列通信，并从仓库（Repository）读取共享状态，角色之间不直接调用。<sup>[12](https://kestra.io/docs/architecture/server-components)</sup>

这些角色分为两个平面。控制平面由无状态的协调角色组成，包括执行器、工作器控制器、调度器、Web 服务器和索引器，它们从不执行用户代码，也无法访问用户基础设施。数据平面是工作器，它是唯一访问用户基础设施和内部存储的角色。<sup>[13](https://kestra.io/docs/architecture)</sup>

各角色职责如下。执行器驱动执行状态机，决定下一个运行哪个任务、重试什么以及执行何时终止，它还运行集群级的服务存活协调器。工作器控制器是集群与其工作器之间唯一的通信点；每个工作器向控制器打开一个持久的双向 gRPC 流，从不订阅作业队列或直接访问数据库。调度器管理除 Flow 触发器之外的所有触发器，每秒检查是否有触发器需要评估。Web 服务器提供 REST API 和 UI，是唯一可从集群外部访问的角色。索引器从队列读取内容并写入仓库后端。<sup>[12](https://kestra.io/docs/architecture/server-components)</sup>

底层组件是可插拔的。队列后端默认是关系型数据库（[PostgreSQL](https://www.edgepedia.org/zh/postgresql) 或 MySQL），测试时使用内存队列，企业版支持 Kafka、Redis 或 AMQP 队列；仓库默认由 PostgreSQL、MySQL 或 H2 支持，企业版使用 Elasticsearch 仓库。内部存储处理执行期间任意大小的文件，插件通过额外的任务和触发器类型、存储实现及集成来扩展核心功能。<sup>[14](https://kestra.io/docs/architecture/main-components)</sup>

## 工作流模型

流程以 YAML 定义，必须包含 `id`、`namespace` 和 `tasks`，还可包含 `triggers`、`labels` 和 `inputs` 等可选字段。任务以完全限定的 Java 类名标注类型，平台以声明式方式处理重试、超时、并发限制和错误处理。<sup>[8](https://github.com/kestra-io/kestra/blob/develop/ui/src/assets/docs/basic.md)</sup><sup> • </sup><sup>[15](https://kestra.io/docs/use-cases/infrastructure)</sup>

Kestra 提供六种主要触发器类别：Schedule 触发器绑定 cron 调度，可选日历限制；Flow 触发器在上游流程以匹配状态完成后启动流程；[Webhook](https://www.edgepedia.org/zh/webhook) 触发器响应传入的 HTTP 请求；Polling 触发器检查外部系统是否有新数据；Realtime 触发器为流式数据源提供毫秒级延迟；MCP Tool 触发器使流程可作为 Kestra MCP 服务器上的命名工具使用，供 Claude Desktop、Claude Code 和 Cursor 等 AI 智能体调用。许多其他触发器，如 S3 文件检测或 SQS 和 Kafka 消息触发器，来自插件。<sup>[9](https://kestra.io/docs/workflow-components/triggers)</sup>

## Kestra 2.0

Kestra 2.0 于 2026 年 9 月 8 日发布，围绕两项变更重建了执行引擎。第一，每个工作器通过单一出站 gRPC 流连接控制平面，因此工作器可部署在另一个区域、不同的云，或仅允许出站连接的网络中，包括气隙环境。第二，队列现在独立于数据库，因此 JDBC 和 Kafka 后端共用一套实现。该版本仍以 Apache 2.0 开源。<sup>[5](https://kestra.io/blogs/kestra-2-0-almost-here)</sup><sup> • </sup><sup>[7](https://kestra.io/blogs/release-2-0/index)</sup>

该版本增加了 AI 原生功能，包括重新设计的 AI Copilot 侧边栏，具有询问、编辑和规划模式；用于流程内 LLM 任务编排的 AI Agents；原生 RAG 工作流支持；以及用于向 AI 智能体暴露流程的 MCP Server 和 MCP Tool 触发器。它还引入了基于操作的 RBAC、策略、用于事件管理的案例，以及一个流程迁移 CLI，可生成每个流程在 2.0 中的变更差异。记录了两项破坏性变更：采用 RFC 9457 问题详情作为单一 API 错误格式，以及从流程级 pluginDefaults 中移除 forced 标志。<sup>[7](https://kestra.io/blogs/release-2-0/index)</sup><sup> • </sup><sup>[16](https://kestra.io/docs/changelog/v2.0.0)</sup><sup> • </sup><sup>[17](https://kestra.io/docs/whats-new-2-0)</sup>

## 发布与支持

Kestra 维护两条发布轨道：LTS 和功能版本。截至当前文档，LTS 2.0 于 2026-09-08 发布，支持至 2027-09；LTS 1.3 于 2026-03-03 发布，支持至 2027-03；功能版本 1.2 和 1.1 在 LTS 1.3 到来时失去支持；LTS 1.0 于 2025-09-09 发布，支持至 2026-09。开源版和企业版镜像均发布 Docker 标签 `latest-lts`，插件发布与 Kestra Core 解耦，拥有自己的版本周期。<sup>[10](https://kestra.io/docs/releases/index)</sup>

## 用例与采用

文档记录的用例包括数据管道和 ETL/ELT、结合 GitOps 的 dbt 工作流、微服务协调、使用 Terraform、Ansible 和 Docker 的基础设施自动化、人在回路审批流程、在 Docker 容器中运行的 Python 工作流，以及包括 RAG 管道和 AI 智能体在内的生成式 AI 工作流。<sup>[1](https://kestra.io/docs/why-kestra)</sup><sup> • </sup><sup>[18](https://kestra.io/docs/use-cases)</sup>

已发布的客户案例包括：Apple 为 200 名运行 ETL 工作负载的机器学习工程师替换了 Airflow；乐华梅兰构建了自助式数据网格，服务 140 家门店的 250 多名工程师；[摩根大通](https://www.edgepedia.org/zh/jpmorgan-chase)（JPMorgan Chase）处理数十亿条网络安全记录，每周为 100 多名分析师执行 4,000 多次 API 拉取。<sup>[19](https://kestra.work/customers)</sup>

## 安全

发布说明记录了多项安全修复和社区报告的公告，包括在 1.3.38 和 1.0.60 版本中修复了利用编码分隔符绕过过滤器实现的未经身份验证的远程代码执行，以及在 1.3.36 中修复了可通过特制 `sort` 查询参数导致管理员账户接管的反射型 XSS。<sup>[20](https://kestra.io/docs/changelog)</sup>

## References

1. [Why Kestra: Simpler, More Powerful Orchestration, Kestra docs](https://kestra.io/docs/why-kestra)
2. [kestra (Kestra Technologies), Hugging Face](https://huggingface.co/kestra)
3. [kestra-io/kestra on GitHub](https://github.com/kestra-io/kestra)
4. [Kestra, Self-Hosted Automation & Workflows, appsgit](https://appsgit.com/apps/kestra)
5. [Kestra 2.0 is almost here, Kestra blog](https://kestra.io/blogs/kestra-2-0-almost-here)
6. [Introducing Kestra first public release, Kestra blog, February 1, 2022](https://kestra.io/blogs/2022-02-01-kestra-opensource)
7. [Kestra 2.0: A New Engine, Workers Anywhere, and Flows as Agent Tools, Kestra blog](https://kestra.io/blogs/release-2-0/index)
8. [kestra/ui basic.md flow documentation, GitHub](https://github.com/kestra-io/kestra/blob/develop/ui/src/assets/docs/basic.md)
9. [Triggers in Kestra: Schedule, Events, Webhooks, Kestra docs](https://kestra.io/docs/workflow-components/triggers)
10. [Releases & LTS Policy in Kestra, Kestra docs](https://kestra.io/docs/releases/index)
11. [Kestra 2.0 Is Coming, and Developers Matter More Than Ever, Kestra blog](https://kestra.io/blogs/kestra-2-0-engineering/index)
12. [Server Components in Kestra Architecture, Kestra docs](https://kestra.io/docs/architecture/server-components)
13. [Architecture in Kestra: Components and Deployment Models, Kestra docs](https://kestra.io/docs/architecture)
14. [Main Components of Kestra Architecture, Kestra docs](https://kestra.io/docs/architecture/main-components)
15. [Automate Infrastructure Workflows in Kestra, Kestra docs](https://kestra.io/docs/use-cases/infrastructure)
16. [v2.0.0 changelog, Kestra](https://kestra.io/docs/changelog/v2.0.0)
17. [What's New in Kestra 2.0, Kestra docs](https://kestra.io/docs/whats-new-2-0)
18. [Kestra Use Cases: Data, ETL, Infra & Microservices, Kestra docs](https://kestra.io/docs/use-cases)
19. [Kestra Customer Stories](https://kestra.work/customers)
20. [Kestra Release Notes / Changelog](https://kestra.io/docs/changelog)

---
*Initially written Oct 26, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 人工智能与数据 › Databases and data systems › Data mining, warehousing, and big data › Big data platforms and frameworks

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/kestra-software

English original: https://www.edgepedia.org/kestra-software
