如何从 Azure 数据工厂触发 Azure Durable Functions?

How to trigger Azure Durable Functions from Azure Data Factory?

我已完成 Durable Function Python 教程并部署到 Azure Functions。 https://docs.microsoft.com/en-us/azure/azure-functions/durable/quickstart-python-vscode

我已经通过(尚未更改教程代码)http://.azurewebsites 成功测试了触发功能。net/api/orchestrators/HelloOrchestrator

我正在阅读来自 http://datanrg.blogspot.com/2020/10/using-durable-functions-in-azure-data.html

如何使用 Azure 数据工厂触发?

1. I tried to add "Azure Function" activity from Azure Data Factory
2. I created Linked Service and entered function name "orchestrators/{HelloOrchestrator}"
3. Selected Method as POST
4. Body set as {"timezone":"Eastern Standard Time"}
4. Add Trigger => " Operation on target Azure Function1 failed: Call to provided Azure function 'orchestrators/{HelloOrchestrator}' failed with status-'InternalServerError' and message - 'Invoking Azure function failed with HttpStatusCode - InternalServerError.'. "

不知是不是用错了activity?

我认为你有权利 activity,你可以只更改为与你所引用的文档中的名称不同的唯一名称。确保在所有引用中重命名。

重新检查函数名称是否正确:

Replace the complete place holder orchestrators/{FunctionName} with function name orchestrators/HelloOrchestrator

其中 HelloOrchestrator 表示由 HTTP 启动函数触发的 DurableFunctions-Orchestrator。不是 HTTP 启动函数本身。

您应该在函数 activity 中提供的函数名称是 DurableFunctions-Orchestrator 的。确保您已将 DurableFunctions-Starter 绑定中的 route 参数更新为 orchestrators/HelloOrchestrator

此外,要检查内部错误的详细信息,您必须检查函数日志。可以检查 Application Insights 日志以查找触发函数应用程序抛出的异常。

要访问 Kudu service,请按照以下步骤操作:

Go to your function app in portal -> Under Development Tools select Advanced tool -> Debug Console (CMD) -> LogFiles -> Application ( C:\home\LogFiles\Application\Functions) -> Select folders accordingly -> log file.