I created an isolated Azure functions for cosmosDB trigger. I'm using Microsoft.Azure.Functions.Worker.Extensions.CosmosDB --version 4.0.0-preview2 to use managed identity. Below is my function.
[Function("CosmosDBTrigger")]
public void Run([CosmosDBTrigger(
databaseName: "testdata",
containerName: "test",
Connection = "connect",
LeaseContainerName = "leases")] IReadOnlyList<MyDocument> input)
{}
local.settings.json
{
"Values": {
connect__accountEndpoint": "https://testdatacosmosdb.documents.azure.com:443/"
}}
I get the error "Cosmos DB connection configuration 'connect' does not exist. Make sure that it is a defined App Setting. I'm not sure if it happening because of isolated azure functions