Deniz
Deniz

Reputation: 1

Azure Function V2 dotnet signalr and cosmos exceptions

I had azure signalR functions triggered with cosmosdb, they were running fine till yesterday. I started to have issues when installing nuget packages on new functions. After some search found this. SignalR negotioan funtion also stopped working and started to return 404.

I had 1.1.14, 2.1.515, 2.2109, and 3.1.301 dotnet versions intalled.

  1. I choosed 2.2.109 in glolbal.json file. Msbuild access exception resolved. SignalR negotion function works with this dotnet sdk. Cosmos trigger functions also work standalone. However when I combine cosmos input with signalR output function stops working and I start to the following expection.

warning CS1701: Assuming assembly reference 'System.Linq.Expressions, Version=4.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' used by 'Microsoft.Azure.DocumentDB.Core' matches identity 'System.Linq.Expressions, Version=4.2.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' of 'System.Linq.Expressions', you may need to supply runtime policy

  1. If I choose 3.1.301 sdk version in global.json cosmos input only functions work. But when I add signalR binding it starts to give the error below

error CS0009: Metadata file 'D:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App\2.2.8\System.Private.CoreLib.dll' could not be opened -- Access to the path is denied.

Azure function version is 2.0. I am using azure webportal to add/edit function.

Any idea how can I resolve this issue?

Upvotes: 0

Views: 178

Answers (1)

Mike Ubezzi
Mike Ubezzi

Reputation: 1027

I wanted to see if you have this issue resolved. Please take a look at your App settings reference for Azure Functions where your FUNCTIONS_EXTENSION_VERSION and FUNCTIONS_V2_COMPATIBILITY_MODE need to be set to support 3x and 2x. Please also take a look at: Azure Functions runtime versions to ensure configuration is correct.

FUNCTIONS_EXTENSION_VERSION = ~3

FUNCTIONS_V2_COMPATIBILITY_MODE = true

Regards, Mike

Upvotes: 0

Related Questions