你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Dataflow - Create Or Update
创建 DataflowResource
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.IoTOperations/instances/{instanceName}/dataflowProfiles/{dataflowProfileName}/dataflows/{dataflowName}?api-version=2025-04-01
URI 参数
名称 | 在 | 必需 | 类型 | 说明 |
---|---|---|---|---|
dataflow
|
path | True |
string minLength: 3maxLength: 63 pattern: ^[a-z0-9][a-z0-9-]*[a-z0-9]$ |
实例数据流的名称Profile 数据流资源 |
dataflow
|
path | True |
string minLength: 3maxLength: 63 pattern: ^[a-z0-9][a-z0-9-]*[a-z0-9]$ |
实例数据流资源的名称 |
instance
|
path | True |
string minLength: 3maxLength: 63 pattern: ^[a-z0-9][a-z0-9-]*[a-z0-9]$ |
实例的名称。 |
resource
|
path | True |
string minLength: 1maxLength: 90 |
资源组的名称。 名称不区分大小写。 |
subscription
|
path | True |
string (uuid) |
目标订阅的 ID。 该值必须是 UUID。 |
api-version
|
query | True |
string minLength: 1 |
用于此作的 API 版本。 |
请求正文
名称 | 必需 | 类型 | 说明 |
---|---|---|---|
extendedLocation | True |
资源的边缘位置。 |
|
properties |
此资源的资源特定属性。 |
响应
名称 | 类型 | 说明 |
---|---|---|
200 OK |
资源“DataflowResource”更新作成功 |
|
201 Created |
资源“DataflowResource”创建作成功 标头
|
|
Other Status Codes |
意外的错误响应。 |
安全性
azure_auth
Azure Active Directory OAuth2 Flow。
类型:
oauth2
流向:
implicit
授权 URL:
https://login.microsoftonline.com/common/oauth2/authorize
作用域
名称 | 说明 |
---|---|
user_impersonation | 模拟用户帐户 |
示例
Dataflow_CreateOrUpdate
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "knnafvkwoeakm",
"sourceSettings": {
"endpointRef": "iixotodhvhkkfcfyrkoveslqig",
"assetRef": "zayyykwmckaocywdkohmu",
"serializationFormat": "Json",
"schemaRef": "pknmdzqll",
"dataSources": [
"chkkpymxhp"
]
},
"builtInTransformationSettings": {
"serializationFormat": "Delta",
"schemaRef": "mcdc",
"datasets": [
{
"key": "qsfqcgxaxnhfumrsdsokwyv",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"schemaRef": "n",
"inputs": [
"mosffpsslifkq"
],
"expression": "aatbwomvflemsxialv"
}
],
"filter": [
{
"type": "Filter",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"sxmjkbntgb"
],
"expression": "n"
}
],
"map": [
{
"type": "NewProperties",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"xsbxuk"
],
"expression": "txoiltogsarwkzalsphvlmt",
"output": "nvgtmkfl"
}
]
},
"destinationSettings": {
"endpointRef": "kybkchnzimerguekuvqlqiqdvvrt",
"dataDestination": "cbrh"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "knnafvkwoeakm",
"sourceSettings": {
"endpointRef": "iixotodhvhkkfcfyrkoveslqig",
"assetRef": "zayyykwmckaocywdkohmu",
"serializationFormat": "Json",
"schemaRef": "pknmdzqll",
"dataSources": [
"chkkpymxhp"
]
},
"builtInTransformationSettings": {
"serializationFormat": "Delta",
"schemaRef": "mcdc",
"datasets": [
{
"key": "qsfqcgxaxnhfumrsdsokwyv",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"schemaRef": "n",
"inputs": [
"mosffpsslifkq"
],
"expression": "aatbwomvflemsxialv"
}
],
"filter": [
{
"type": "Filter",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"sxmjkbntgb"
],
"expression": "n"
}
],
"map": [
{
"type": "NewProperties",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"xsbxuk"
],
"expression": "txoiltogsarwkzalsphvlmt",
"output": "nvgtmkfl"
}
]
},
"destinationSettings": {
"endpointRef": "kybkchnzimerguekuvqlqiqdvvrt",
"dataDestination": "cbrh"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "knnafvkwoeakm",
"sourceSettings": {
"endpointRef": "iixotodhvhkkfcfyrkoveslqig",
"assetRef": "zayyykwmckaocywdkohmu",
"serializationFormat": "Json",
"schemaRef": "pknmdzqll",
"dataSources": [
"chkkpymxhp"
]
},
"builtInTransformationSettings": {
"serializationFormat": "Delta",
"schemaRef": "mcdc",
"datasets": [
{
"key": "qsfqcgxaxnhfumrsdsokwyv",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"schemaRef": "n",
"inputs": [
"mosffpsslifkq"
],
"expression": "aatbwomvflemsxialv"
}
],
"filter": [
{
"type": "Filter",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"sxmjkbntgb"
],
"expression": "n"
}
],
"map": [
{
"type": "NewProperties",
"description": "Lorem ipsum odor amet, consectetuer adipiscing elit.",
"inputs": [
"xsbxuk"
],
"expression": "txoiltogsarwkzalsphvlmt",
"output": "nvgtmkfl"
}
]
},
"destinationSettings": {
"endpointRef": "kybkchnzimerguekuvqlqiqdvvrt",
"dataDestination": "cbrh"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Dataflow_CreateOrUpdate_ComplexContextualization
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/aio-to-adx-contexualized?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"$context(quality).*"
],
"output": "enriched.*"
}
],
"datasets": [
{
"key": "quality",
"inputs": [
"$source.country",
"$context.country"
],
"expression": "$1 == $2"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "adx-endpoint",
"dataDestination": "mytable"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"$context(quality).*"
],
"output": "enriched.*"
}
],
"datasets": [
{
"key": "quality",
"inputs": [
"$source.country",
"$context.country"
],
"expression": "$1 == $2"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "adx-endpoint",
"dataDestination": "mytable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"$context(quality).*"
],
"output": "enriched.*"
}
],
"datasets": [
{
"key": "quality",
"inputs": [
"$source.country",
"$context.country"
],
"expression": "$1 == $2"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "adx-endpoint",
"dataDestination": "mytable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Dataflow_CreateOrUpdate_ComplexEventHub
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/aio-to-event-hub-transformed?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"builtInTransformationSettings": {
"filter": [
{
"inputs": [
"temperature.Value",
"\"Tag 10\".Value"
],
"expression": "$1 > 9000 && $2 >= 8000"
}
],
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"temperature.Value",
"\"Tag 10\".Value"
],
"expression": "($1+$2)/2",
"output": "AvgTemp.Value"
},
{
"inputs": [],
"expression": "true",
"output": "dataflow-processed"
},
{
"inputs": [
"temperature.SourceTimestamp"
],
"expression": "",
"output": ""
},
{
"inputs": [
"\"Tag 10\""
],
"expression": "",
"output": "pressure"
},
{
"inputs": [
"temperature.Value"
],
"expression": "cToF($1)",
"output": "temperatureF.Value"
},
{
"inputs": [
"\"Tag 10\".Value"
],
"expression": "scale ($1,0,10,0,100)",
"output": "\"Scale Tag 10\".Value"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "event-hub-endpoint",
"dataDestination": "myuniqueeventhub"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"$context(quality).*"
],
"output": "enriched.*"
}
],
"datasets": [
{
"key": "quality",
"inputs": [
"$source.country",
"$context.country"
],
"expression": "$1 == $2"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "adx-endpoint",
"dataDestination": "mytable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"map": [
{
"inputs": [
"*"
],
"output": "*"
},
{
"inputs": [
"$context(quality).*"
],
"output": "enriched.*"
}
],
"datasets": [
{
"key": "quality",
"inputs": [
"$source.country",
"$context.country"
],
"expression": "$1 == $2"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "adx-endpoint",
"dataDestination": "mytable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Dataflow_CreateOrUpdate_FilterToTopic
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/mqtt-filter-to-topic?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"filter": [
{
"type": "Filter",
"description": "filter-datapoint",
"inputs": [
"temperature.Value",
"\"Tag 10\".Value"
],
"expression": "$1 > 9000 && $2 >= 8000"
}
],
"map": [
{
"type": "PassThrough",
"inputs": [
"*"
],
"output": "*"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataDestination": "data/filtered/thermostat"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"filter": [
{
"type": "Filter",
"description": "filter-datapoint",
"inputs": [
"temperature.Value",
"\"Tag 10\".Value"
],
"expression": "$1 > 9000 && $2 >= 8000"
}
],
"map": [
{
"type": "PassThrough",
"inputs": [
"*"
],
"output": "*"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataDestination": "data/filtered/thermostat"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"name": "transformation1",
"builtInTransformationSettings": {
"filter": [
{
"type": "Filter",
"description": "filter-datapoint",
"inputs": [
"temperature.Value",
"\"Tag 10\".Value"
],
"expression": "$1 > 9000 && $2 >= 8000"
}
],
"map": [
{
"type": "PassThrough",
"inputs": [
"*"
],
"output": "*"
}
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataDestination": "data/filtered/thermostat"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Dataflow_CreateOrUpdate_SimpleEventGrid
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/aio-to-event-grid?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"thermostats/+/telemetry/temperature/#"
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "event-grid-endpoint",
"dataDestination": "factory/telemetry"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"thermostats/+/telemetry/temperature/#"
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "event-grid-endpoint",
"dataDestination": "factory/telemetry"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"thermostats/+/telemetry/temperature/#"
]
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "event-grid-endpoint",
"dataDestination": "factory/telemetry"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Dataflow_CreateOrUpdate_SimpleFabric
示例请求
PUT https://management.azure.com/subscriptions/F8C729F9-DF9C-4743-848F-96EE433D8E53/resourceGroups/rgiotoperations/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/aio-to-fabric?api-version=2025-04-01
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"builtInTransformationSettings": {
"serializationFormat": "Parquet",
"schemaRef": "aio-sr://exampleNamespace/exmapleParquetSchema:1.0.0"
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "fabric-endpoint",
"dataDestination": "telemetryTable"
}
}
]
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
}
}
示例响应
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"builtInTransformationSettings": {
"serializationFormat": "Parquet",
"schemaRef": "aio-sr://exampleNamespace/exmapleParquetSchema:1.0.0"
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "fabric-endpoint",
"dataDestination": "telemetryTable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
Azure-AsyncOperation: https://contoso.com/operationstatus
{
"properties": {
"mode": "Enabled",
"operations": [
{
"operationType": "Source",
"name": "source1",
"sourceSettings": {
"endpointRef": "aio-builtin-broker-endpoint",
"dataSources": [
"azure-iot-operations/data/thermostat"
]
}
},
{
"operationType": "BuiltInTransformation",
"builtInTransformationSettings": {
"serializationFormat": "Parquet",
"schemaRef": "aio-sr://exampleNamespace/exmapleParquetSchema:1.0.0"
}
},
{
"operationType": "Destination",
"name": "destination1",
"destinationSettings": {
"endpointRef": "fabric-endpoint",
"dataDestination": "telemetryTable"
}
}
],
"provisioningState": "Succeeded"
},
"extendedLocation": {
"name": "qmbrfwcpwwhggszhrdjv",
"type": "CustomLocation"
},
"id": "/subscriptions/0000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup123/providers/Microsoft.IoTOperations/instances/resource-name123/dataflowProfiles/resource-name123/dataflows/resource-name123",
"name": "jxhcpwgfkxqasbexkookvxk",
"type": "zkuozvgjseokfchkscoswthzjdry",
"systemData": {
"createdBy": "ssvaslsmudloholronopqyxjcu",
"createdByType": "User",
"createdAt": "2024-08-09T18:13:29.389Z",
"lastModifiedBy": "gnicpuszwd",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-08-09T18:13:29.389Z"
}
}
定义
名称 | 说明 |
---|---|
created |
创建资源的标识的类型。 |
Dataflow |
数据流 BuiltIn Transformation 数据集属性 |
Dataflow |
数据流 BuiltIn Transformation 筛选器属性 |
Dataflow |
数据流 BuiltIn Transformation 映射属性 |
Dataflow |
数据流 BuiltIn Transformation 属性 |
Dataflow |
数据流目标作属性 |
Dataflow |
数据流类型映射属性 |
Dataflow |
数据流作属性。 注意 - 只允许一个方法用于一个条目。 |
Dataflow |
数据流资源属性 |
Dataflow |
实例数据流Profile 数据流资源 |
Dataflow |
数据流源作属性 |
Error |
资源管理错误附加信息。 |
Error |
错误详细信息。 |
Error |
错误响应 |
Extended |
扩展位置是 Azure 位置的扩展。 他们提供了一种使用已启用 Azure ARC 的 Kubernetes 群集作为部署 Azure 服务实例的目标位置的方法。 |
Extended |
已接受 ExtendedLocation 的枚举类型。 |
Filter |
筛选器类型属性 |
Operational |
模式属性 |
Operation |
数据流作类型属性 |
Provisioning |
定义资源状态的枚举。 |
Source |
序列化格式属性 |
system |
与创建和上次修改资源相关的元数据。 |
Transformation |
转换格式属性 |
createdByType
创建资源的标识的类型。
值 | 说明 |
---|---|
Application | |
Key | |
ManagedIdentity | |
User |
DataflowBuiltInTransformationDataset
数据流 BuiltIn Transformation 数据集属性
名称 | 类型 | 说明 |
---|---|---|
description |
string maxLength: 256 |
用户提供了数据集的可选说明。 |
expression |
string |
从 Broker 状态存储扩充数据的条件。 示例:$1 < 0 ||$1 > $2 (假设输入部分 $1 和 $2 提供) |
inputs |
string[] |
要从中转站状态存储进行扩充的字段列表。 |
key |
string maxLength: 64 |
数据集的键。 |
schemaRef |
string |
对描述数据集的架构的引用。 允许:JSON 架构/草稿-7。 |
DataflowBuiltInTransformationFilter
数据流 BuiltIn Transformation 筛选器属性
名称 | 类型 | 默认值 | 说明 |
---|---|---|---|
description |
string maxLength: 256 |
用户提供了筛选器的可选说明。 |
|
expression |
string |
筛选数据的条件。 可以使用 {n} 引用输入字段,其中 n 是从 1 开始的输入字段的索引。 示例:$1 < 0 ||$1 > $2 (假设输入部分 $1 和 $2 提供) |
|
inputs |
string[] |
用于在 JSON 路径表达式中筛选的字段列表。 |
|
type | Filter |
数据流作的类型。 |
DataflowBuiltInTransformationMap
数据流 BuiltIn Transformation 映射属性
名称 | 类型 | 说明 |
---|---|---|
description |
string maxLength: 256 |
用户提供了映射函数的可选说明。 |
expression |
string |
将输入字段(s)修改为最终输出字段。 示例:$1 * 2.2 (假设提供输入部分 $1) |
inputs |
string[] |
JSON 路径表达式中映射的字段列表。 |
output |
string |
输出记录中要组织的输入字段的位置和方式。 |
type |
转换类型。 |
DataflowBuiltInTransformationSettings
数据流 BuiltIn Transformation 属性
名称 | 类型 | 默认值 | 说明 |
---|---|---|---|
datasets |
从 Broker State Store 扩充数据。 数据集引用 Broker State Store 中的密钥。 |
||
filter |
根据条件筛选输入记录或数据点。 |
||
map |
将输入映射到输出消息。 |
||
schemaRef |
string |
对描述转换输出的架构的引用。 |
|
serializationFormat | Json |
序列化格式。 自选;默认值为 JSON。 允许的值 JSON 架构/草稿 7,Parquet。 默认值:Json |
DataflowDestinationOperationSettings
数据流目标作属性
名称 | 类型 | 说明 |
---|---|---|
dataDestination |
string minLength: 1 |
目标位置可以是主题或表名称。 支持具有$topic、$systemProperties、$userProperties、$payload、$context和$subscription的动态值。 |
endpointRef |
string |
对终结点 CR 的引用。 可以是 Broker、Kafka、Fabric、ADLS、ADX 类型。 |
DataflowMappingType
数据流类型映射属性
值 | 说明 |
---|---|
BuiltInFunction |
内置函数类型 |
Compute |
计算类型 |
NewProperties |
新建属性类型 |
PassThrough |
直通类型 |
Rename |
重命名类型 |
DataflowOperation
数据流作属性。 注意 - 只允许一个方法用于一个条目。
名称 | 类型 | 说明 |
---|---|---|
builtInTransformationSettings |
内置转换配置。 |
|
destinationSettings |
目标配置。 |
|
name |
string maxLength: 64 |
转换的可选用户提供的名称。 |
operationType |
作的类型。 |
|
sourceSettings |
源配置。 |
DataflowProperties
数据流资源属性
名称 | 类型 | 默认值 | 说明 |
---|---|---|---|
mode | Enabled |
数据流模式。 自选;默认值为 Enabled。 |
|
operations |
作列表,包括源引用和目标引用以及转换。 |
||
provisioningState |
上次作的状态。 |
DataflowResource
实例数据流Profile 数据流资源
名称 | 类型 | 说明 |
---|---|---|
extendedLocation |
资源的边缘位置。 |
|
id |
string (arm-id) |
资源的完全限定资源 ID。 例如“/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}” |
name |
string |
资源的名称 |
properties |
此资源的资源特定属性。 |
|
systemData |
包含 createdBy 和 modifiedBy 信息的 Azure 资源管理器元数据。 |
|
type |
string |
资源的类型。 例如“Microsoft.Compute/virtualMachines”或“Microsoft.Storage/storageAccounts” |
DataflowSourceOperationSettings
数据流源作属性
名称 | 类型 | 默认值 | 说明 |
---|---|---|---|
assetRef |
string |
引用终结点中的数据源自 Azure 设备注册表中的资源。 |
|
dataSources |
string[] minLength: 1 |
源位置列表。 可以是 Broker 或 Kafka 主题。 支持通配符 #和 +。 |
|
endpointRef |
string |
对数据流终结点资源的引用。 只能是 Broker 和 Kafka 类型。 |
|
schemaRef |
string |
架构 CR 参考。 数据将根据架构进行反序列化,如果数据不匹配,则会将其删除。 |
|
serializationFormat | Json |
内容是 JSON 架构。 允许:JSON 架构/草稿-7。 |
ErrorAdditionalInfo
资源管理错误附加信息。
名称 | 类型 | 说明 |
---|---|---|
info |
object |
其他信息。 |
type |
string |
其他信息类型。 |
ErrorDetail
错误详细信息。
名称 | 类型 | 说明 |
---|---|---|
additionalInfo |
错误附加信息。 |
|
code |
string |
错误代码。 |
details |
错误详细信息。 |
|
message |
string |
错误消息。 |
target |
string |
错误目标。 |
ErrorResponse
错误响应
名称 | 类型 | 说明 |
---|---|---|
error |
错误对象。 |
ExtendedLocation
扩展位置是 Azure 位置的扩展。 他们提供了一种使用已启用 Azure ARC 的 Kubernetes 群集作为部署 Azure 服务实例的目标位置的方法。
名称 | 类型 | 说明 |
---|---|---|
name |
string |
扩展位置的名称。 |
type |
ExtendedLocation 的类型。 |
ExtendedLocationType
已接受 ExtendedLocation 的枚举类型。
值 | 说明 |
---|---|
CustomLocation |
CustomLocation 类型 |
FilterType
筛选器类型属性
值 | 说明 |
---|---|
Filter |
筛选器类型 |
OperationalMode
模式属性
值 | 说明 |
---|---|
Disabled |
Disabled 等效于 False。 |
Enabled |
Enabled 等效于 True |
OperationType
数据流作类型属性
值 | 说明 |
---|---|
BuiltInTransformation |
数据流 BuiltIn 转换作 |
Destination |
数据流目标作 |
Source |
数据流源作 |
ProvisioningState
定义资源状态的枚举。
值 | 说明 |
---|---|
Accepted |
资源已被接受。 |
Canceled |
资源创建已取消。 |
Deleting |
资源正在删除。 |
Failed |
资源创建失败。 |
Provisioning |
正在预配资源。 |
Succeeded |
已创建资源。 |
Updating |
资源正在更新。 |
SourceSerializationFormat
序列化格式属性
值 | 说明 |
---|---|
Json |
JSON 格式 |
systemData
与创建和上次修改资源相关的元数据。
名称 | 类型 | 说明 |
---|---|---|
createdAt |
string (date-time) |
资源创建时间戳(UTC)。 |
createdBy |
string |
创建资源的标识。 |
createdByType |
创建资源的标识的类型。 |
|
lastModifiedAt |
string (date-time) |
上次修改的资源时间戳(UTC) |
lastModifiedBy |
string |
上次修改资源的标识。 |
lastModifiedByType |
上次修改资源的标识的类型。 |
TransformationSerializationFormat
转换格式属性
值 | 说明 |
---|---|
Delta |
增量格式 |
Json |
JSON 格式 |
Parquet |
Parquet 格式 |