I am defining an Azure Function App as follows:
public static void Run(
[CosmosDBTrigger(
databaseName: "dbName",
collectionName: "collectiontoMonitor",
ConnectionStringSetting = "collectionConnectionStringSettingName",
LeaseDatabaseName = "LeaseDBName",
LeaseCollectionName = "LeaseCollection",
LeaseConnectionStringSetting = "LeaseConnectionString",
LeaseCollectionPrefix ="funcName")]IReadOnlyList<Document> input, ILogger log)
{
..
}
I am publishing from visual studio and it works without any errors. However, the Function is never triggered even after changes in the Collection. If I run the function manually, I get error:
Value cannot be null. Parameter name: o
The above is the exact error message and I don't have any parameter by the name 'o'. What could I be missing.
Update: In case it makes a difference, the Function App is under a different subscription than the Cosmos.