在Azure Function应用中编程 [英] Programing in Azure Function Apps

查看:62
本文介绍了在Azure Function应用中编程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有以下要求:

外部应用程序将使用有效负载触发Azure事件网格中的事件,该负载将执行功能应用程序.该功能应用程序应该更新SQL数据库以启用高级威胁防护.

External App will trigger event in Azure Event Grid with a payload which will execute Function App. This function app is supposed to update the SQL Database to enable Advance threat protection.

我尝试使用以下代码打开连接,但失败,并显示不支持关键字:'authentication'".我正在使用具有ADO .NET Active Directory密码身份验证值的App设置.我可以从连接到数据库 使用AD单点登录的门户.

I tried opening the connection with following code but it fails with "Keyword not supported: 'authentication'". I'm using App setting which is having value of ADO .NET Active directory password Authentication. I'm able connect to the database from portal using AD single sign on.

功能应用代码...

function App code...

#r " Microsoft.Azure.EventGrid"

推荐答案

基于

Based on this doc, it seems that Azure Active Directory Authentication is supported only with .NET Framework 4.6 and though support for Access Tokens is available in .NET Core 2.2, its not available yet for Azure Functions.

我认为

I think Managed Identity (now its just Identity in the portal) is something that you might want to look at.
Here is a doc which explains how to set this up for App Service and SQL. It should be fairly similar for Functions as well.


这篇关于在Azure Function应用中编程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆