# Microsoft Azure 数字孪生（Microsoft Azure Digital Twins）

**Microsoft Azure 数字孪生（Microsoft Azure Digital Twins）** 是一项 Azure 物联网（IoT）服务，用于把建筑物、工厂、风电场和城市等物理环境构建成数字副本，并以模型、孪生和关系组成的实时图来表示，由设备和业务系统数据保持最新。Microsoft 于 2018 年 9 月 24 日在 Ignite 大会上宣布该服务进入公共预览版，并于 2020 年 12 月 8 日正式发布。<sup>[1](https://azure.microsoft.com/en-us/blog/announcing-azure-digital-twins-create-digital-replicas-of-spaces-and-infrastructure-using-cloud-ai-and-iot/)</sup><sup> • </sup><sup>[2](https://azure.microsoft.com/en-us/blog/azure-digital-twins-now-generally-available-create-iot-solutions-that-model-the-real-world/)</sup>

| 关键事实 | 详情 |
|---|---|
| 存储内容 | 孪生图：由关系连接的数字孪生（用户定义模型的实例），表示整个环境<sup>[3](https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/digital-twins/concepts-twins-graph.md)</sup> |
| 建模语言 | 数字孪生定义语言（DTDL），一种类似 JSON 的语言，通过属性、组件和关系描述实体类型<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup> |
| 数据源 | 用于物联网和 IoT Edge 设备的 IoT Hub；用于业务系统数据的 REST API 和连接器（如 Logic Apps）<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup> |
| 规模限制 | 默认每个实例 2,000,000 个孪生和 20,000,000 个关系；每个订阅每个区域 10 个实例，可调整至 50 个<sup>[5](https://learn.microsoft.com/sr-latn-rs/azure///digital-twins/reference-service-limits)</sup> |
| 查询行为 | 对图提供类 SQL 查询 API；更改最多可能需要 10 秒才出现在查询结果中，而 DigitalTwins API 会立即反映更改<sup>[6](https://learn.microsoft.com/da-dk/azure/digital-twins/concepts-query-language)</sup> |
| 历史记录 | 数据历史记录功能将实例连接到 Azure Data Explorer，使图更新自动记录为历史数据并可随时间查询<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup> |
| 时间线 | 2018 年 9 月 24 日公共预览；Build 2020 宣布下一迭代；2020 年 12 月 8 日正式发布<sup>[1](https://azure.microsoft.com/en-us/blog/announcing-azure-digital-twins-create-digital-replicas-of-spaces-and-infrastructure-using-cloud-ai-and-iot/)</sup><sup> • </sup><sup>[7](https://azure.microsoft.com/en-us/blog/virtual-build-spotlights-iot-updates-and-rollouts/)</sup><sup> • </sup><sup>[2](https://azure.microsoft.com/en-us/blog/azure-digital-twins-now-generally-available-create-iot-solutions-that-model-the-real-world/)</sup> |

## 模型与孪生图

[Azure 数字孪生](https://www.edgepedia.org/zh/azure-digital-twins)中的解决方案从**模型**开始。模型通过状态属性、组件和关系描述环境中的一类实体，例如楼宇、楼层或电梯。模型用 DTDL 编写，开发者可以从零设计模型集，也可以采用预构建的 DTDL 行业本体，例如 RealEstateCore 智能楼宇本体、智慧城市本体和能源电网本体。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup><sup> • </sup><sup>[8](https://learn.microsoft.com/en-us/azure/digital-twins/)</sup>

模型上传后，客户端应用程序就可以创建它的实例。每个实例都是一个**数字孪生**，表示一个具体实体，例如一个名为 GroundFloor 的 Floor 类型孪生。孪生之间通过关系连接，而一个孪生可以拥有哪些关系，是其模型的一部分：Floor 模型可以定义一个指向 Room 孪生的 `contains` 关系，此后该服务允许从任意 Floor 孪生到任意 Room 孪生（包括 Room 子类型）建立 `contains` 关系。由此得到的节点（孪生）和边（关系）集合就是孪生图，它表示整个环境。孪生数据和关系数据均以 JSON 格式存储。<sup>[3](https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/digital-twins/concepts-twins-graph.md)</sup>

DTDL 与更广泛的 Azure 物联网生态系统共享：该语言的版本 2 也用于其他 Azure 物联网服务中的数据模型，包括 IoT Plug and Play；DTDL 版本 3 规范已发布在 GitHub 上。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup><sup> • </sup><sup>[5](https://learn.microsoft.com/sr-latn-rs/azure///digital-twins/reference-service-limits)</sup>

## 数据流入、流出与处理

该服务旨在让图保持为实时表示，而不是静态模型。**流入**主要来自 Azure IoT Hub，它连接物联网和 IoT Edge 设备；这些由 IoT Hub 管理的设备会作为孪生图的一部分出现，并提供驱动模型的数据。解决方案可以创建新的 IoT Hub，也可以连接一个已有的 IoT Hub 及其已经管理的设备。其他数据源（包括业务系统）可以通过 REST API 或连接到 Logic Apps 等服务的连接器向图提供数据。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup>

事件系统使图保持最新，并可触发自定义处理。可以附加 Azure Functions 等外部计算，以针对传入事件实现业务逻辑。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup>

**流出**将孪生数据路由到下游服务。事件路由使用 Event Hubs、Event Grid 和 Service Bus，通过自定义流发送数据，例如将数据存储在 Azure Data Lake 中、用 [Azure Synapse Analytics](https://www.edgepedia.org/zh/azure-synapse-analytics) 分析数据、与 Logic Apps 工作流集成，或向自定义应用程序提供数据。数据历史记录功能将实例直接连接到 Azure Data Explorer 集群，自动将图更新记录为历史数据，以便之后使用 Azure 数字孪生查询插件随时间查询。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup>

在可视化方面，Azure Digital Twins Explorer 提供用于构建图并与图交互的界面；3D Scenes Studio（预览版）提供低代码 3D 环境，领域专家可在其中将 3D 资产映射到孪生，并基于运营数据定义 UI 交互性和业务逻辑。<sup>[4](https://learn.microsoft.com/en-us/azure/digital-twins/overview)</sup>

## 查询

该服务在实时执行环境上公开查询 API，支持对属性值、关系、关系属性和模型信息的搜索条件，并提供 SELECT、FROM、MATCH、JOIN 和 WHERE 等子句。所有查询操作均区分大小写；属性名拼写错误或大小写不正确会返回空结果集，而不会报错。<sup>[6](https://learn.microsoft.com/da-dk/azure/digital-twins/concepts-query-language)</sup>

实践中两个时序特性很重要。更改图数据后，最多可能经过 10 秒，更改才会出现在查询结果中，因此需要立即读取的应用程序应改用 DigitalTwins API（GetById）或 SDK 调用（GetDigitalTwin）。查询语言本身只涵盖孪生和关系的当前状态；历史分析通过到 Azure Data Explorer 的数据历史记录连接进行。<sup>[6](https://learn.microsoft.com/da-dk/azure/digital-twins/concepts-query-language)</sup>

## 服务限制与限流

默认功能限制包括：每个实例 2,000,000 个孪生、总共 20,000,000 个关系、单个孪生最多 50,000 个传出关系、每个实例 10,000 个模型、单个孪生的 JSON 正文最大 32 KB，以及每个实例 6 个终结点和 6 个路由。查询限制包括：每页 1,000 项、50 个 AND/OR 表达式、IN 子句中 50 个数组项、每个查询 8,000 个字符，以及 5 个 JOIN；其中若干项可通过支持工单调整。<sup>[5](https://learn.microsoft.com/sr-latn-rs/azure///digital-twins/reference-service-limits)</sup>

速率限制包括：Digital Twins API 每秒 1,000 个读取请求和 1,000 个修补请求；所有孪生和关系合计每秒 500 个创建/删除操作；每秒 500 个查询请求。有一项限制是固定的：单个孪生或其关系每秒 10 个创建/更新/删除操作。服务会自动缩放资源以满足速率限制，但内部缩放可能需要 5 到 30 分钟，在此期间应用程序可能遇到 429 限流错误；SDK 实现了重试逻辑，服务会返回 `Retry-After` 标头。Microsoft 建议将大型部署划分为多个实例（例如按区域或租户），而不是使用一个大型图。<sup>[5](https://learn.microsoft.com/sr-latn-rs/azure///digital-twins/reference-service-limits)</sup>

## 历史与生态系统

2018 年的预览版将该服务定位为围绕空间智能图来建模人、地点和设备，并具备用于数据隔离的多租户和嵌套租户、通过 Azure Active Directory 实现的基于角色的访问控制，以及与 Azure 分析、AI、存储、Azure Maps、混合现实、Dynamics 365 和 Office 365 的集成。<sup>[1](https://azure.microsoft.com/en-us/blog/announcing-azure-digital-twins-create-digital-replicas-of-spaces-and-infrastructure-using-cloud-ai-and-iot/)</sup> 在 Build 2020 上，Microsoft 宣布了下一迭代，围绕完整的图拓扑、实时执行环境和基于 JSON-LD 标准的开放建模语言进行重建，它最终成为基于 DTDL 并正式发布的服务。<sup>[7](https://azure.microsoft.com/en-us/blog/virtual-build-spotlights-iot-updates-and-rollouts/)</sup>

Microsoft 于 2020 年 5 月共同创立了数字孪生联盟（Digital Twins Consortium）；在正式发布公告中，Microsoft 报告该联盟拥有来自企业、政府机构和学术界的 170 多个成员，致力于数字孪生技术的共享词汇、架构、安全性和兼容性。<sup>[2](https://azure.microsoft.com/en-us/blog/azure-digital-twins-now-generally-available-create-iot-solutions-that-model-the-real-world/)</sup>

早期部署展示了用例范围。斗山重工业建设（Doosan Heavy Industries and Construction）与 Microsoft 和 [Bentley Systems](https://www.edgepedia.org/zh/bentley-systems) 合作，为其风电场构建数字孪生，将实时和历史物联网、天气及运营数据与物理模型和机器学习模型结合起来，以预测每台涡轮机的输出并调整桨距角和性能。[江森自控](https://www.edgepedia.org/zh/johnson-controls)（Johnson Controls）将其 OpenBlue Digital Twin 平台与该服务集成，用于楼宇管理；Ansys 提供了其 Twin Builder 仿真孪生的原生集成；布鲁克菲尔德地产（Brookfield Properties）与 Willow 合作，使用 RealEstateCore 的开源模型为曼哈顿西一号（One Manhattan West）物业构建数字副本。<sup>[2](https://azure.microsoft.com/en-us/blog/azure-digital-twins-now-generally-available-create-iot-solutions-that-model-the-real-world/)</sup>

## 在 Microsoft 产品组合及竞品中的定位

Azure 数字孪生在 Microsoft 的产品组合中占据一个特定位置。它是一个平台即服务型孪生图，并带有形式化的建模语言，不同于 IoT Hub 中的设备孪生——后者表示单个设备，而不是一个环境。Microsoft 明确将其与 **digital twin builder（预览版）** 区分开来；后者是 [Microsoft Fabric](https://www.edgepedia.org/zh/microsoft-fabric) 的 Real-Time Intelligence 工作负载中的一个项，通过本体以低代码/无代码工具建模业务概念，并将数据存储在 OneLake 中；Fabric 文档指出，digital twin builder 与 Azure 数字孪生服务不同。<sup>[3](https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/digital-twins/concepts-twins-graph.md)</sup><sup> • </sup><sup>[9](https://learn.microsoft.com/en-us/fabric/real-time-intelligence/digital-twin-builder/overview)</sup>

与 [AWS IoT TwinMaker](https://www.edgepedia.org/zh/aws-iot-twinmaker) 相比，两个服务采用不同的架构方法。Azure 数字孪生以预先用 DTDL 构建的基于图的语义模型为中心，而 TwinMaker 侧重于把来自不同来源的数据拼接起来，例如 AWS IoT SiteWise、Kinesis Video Streams 和 [Amazon S3](https://www.edgepedia.org/zh/amazon-s3) 中的 3D 模型，且不要求预先提供完整的语义模型。独立评估已使用城市交通仿真等场景，按集成工作量和成本等标准比较这两个平台以及 Eclipse Ditto。<sup>[10](https://inferensys.com/differences/robotics-simulation-and-synthetic-environment-platforms/cloud-robotics-simulation-platforms/azure-digital-twins-vs-aws-iot-twinmaker)</sup><sup> • </sup><sup>[11](https://www.researchgate.net/publication/404056151_Evaluating_Software_Platforms_for_Digital_Twin_Creation_Features_Capabilities_and_Tradeoffs)</sup>

## References

1. [Announcing Azure Digital Twins: Create digital replicas of spaces and infrastructure using cloud, AI and IoT, Microsoft Azure Blog (September 24, 2018)](https://azure.microsoft.com/en-us/blog/announcing-azure-digital-twins-create-digital-replicas-of-spaces-and-infrastructure-using-cloud-ai-and-iot/)
2. [Azure Digital Twins now generally available: Create IoT solutions that model the real world, Microsoft Azure Blog (December 8, 2020)](https://azure.microsoft.com/en-us/blog/azure-digital-twins-now-generally-available-create-iot-solutions-that-model-the-real-world/)
3. [Digital twins and the twin graph, MicrosoftDocs/azure-docs, GitHub](https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/digital-twins/concepts-twins-graph.md)
4. [What is Azure Digital Twins?, Microsoft Learn](https://learn.microsoft.com/en-us/azure/digital-twins/overview)
5. [Service limits – Azure Digital Twins, Microsoft Learn](https://learn.microsoft.com/sr-latn-rs/azure///digital-twins/reference-service-limits)
6. [Query language – Azure Digital Twins, Microsoft Learn](https://learn.microsoft.com/da-dk/azure/digital-twins/concepts-query-language)
7. [Virtual Build spotlights IoT updates and rollouts, Microsoft Azure Blog (2020)](https://azure.microsoft.com/en-us/blog/virtual-build-spotlights-iot-updates-and-rollouts/)
8. [Azure Digital Twins documentation, Microsoft Learn](https://learn.microsoft.com/en-us/azure/digital-twins/)
9. [What is digital twin builder (preview)?, Microsoft Fabric, Microsoft Learn](https://learn.microsoft.com/en-us/fabric/real-time-intelligence/digital-twin-builder/overview)
10. [Azure Digital Twins vs AWS IoT TwinMaker: In-Depth Comparison, Inference Systems](https://inferensys.com/differences/robotics-simulation-and-synthetic-environment-platforms/cloud-robotics-simulation-platforms/azure-digital-twins-vs-aws-iot-twinmaker)
11. [Evaluating Software Platforms for Digital Twin Creation: Features, Capabilities, and Tradeoffs, ResearchGate](https://www.researchgate.net/publication/404056151_Evaluating_Software_Platforms_for_Digital_Twin_Creation_Features_Capabilities_and_Tradeoffs)

---
*Initially written Oct 15, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 软件与编程 › Named software products and platforms › Cloud, virtualization, and containers

Copyright 2026 Edgepedia

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

Source: https://www.edgepedia.org/zh/microsoft-azure-digital-twins

English original: https://www.edgepedia.org/microsoft-azure-digital-twins
