我创建了一个管道和一个触发器,我试图让触发器在部署后立即自动启动。我在文档中看到部署后触发器的状态为“停止”,我想问一下如何在模板部署中更改它,以便在每次部署后都不需要使用 powershell 脚本。
我试图在我的 TD 中使用“runtimeState”参数,但它被替换为“stopped”。
这是我的触发器:
{
"name": "[concat(variables('factoryName'), '/periodicTrigger')]",
"type": "Microsoft.DataFactory/factories/triggers",
"apiVersion": "2018-06-01",
"properties": {
"description": "Periodic trigger for the backup pipeline.",
"annotations": [],
"runtimeState": "Started",
"pipelines": [
{
"pipelineReference": {
"referenceName": "[concat(variables('mainStorageName'),'backupPipeline')]",
"type": "PipelineReference"
},
"parameters": {}
}
],
"type": "ScheduleTrigger",
"typeProperties": {
"recurrence": {
"frequency": "Day",
"interval": 1,
"startTime": "2018-08-21T13:28:07.785Z",
"timeZone": "UTC",
"schedule": {
"minutes": [
0
],
"hours": [
3
]
}
}
}
},
"dependsOn": [
"[concat(variables('factoryId'), '/pipelines/',concat(variables('mainStorageName'),'backupPipeline'))]"
]
},
Run Code Online (Sandbox Code Playgroud)