Azure / Azure/azure-functions-core-tools

.NET6 Isolated Functions indexed before host configured

Open
#3,473 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
1.5k
Forks
498
Avg merge
4d 20h
Merged PRs (30d)
14

Description

migrating for .NET6 V4 in-process function to isolated function. Previously using Microsoft.Azure.Functions.Extensions to inherit FunctionsStartup and setup everything. Upon switching I am getting many "Make sure that it is a defined App Setting" for my Azure Functions Trigger referencing app settings (Timer Triggers, ServiceBus Triggers).

I did some debugging and it is throwing these errors before it even creates the 'Host' (new HostBuilder...Build()) and run (Host.RunAsync()) which seems odd. In fact, if my Main(..) method is completely empty it still starts and beings to throw errors. I don't use local.settings.json, everything is through appsettings.json.

I'm not sure if this is issue with core tools or the actual runtime, can someone help. Hopefully this is not limitation of isolated process compared to in-process. I would have expected host to be configured and run before loading triggers, so that configuration can be leveraged.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the .NET 6 isolated-function migration with appsettings.json, an empty Main method, and the affected Timer or ServiceBus triggers. Compare when trigger indexing occurs with when HostBuilder configuration is applied; done means establishing whether this is a core-tools or runtime limitation and documenting or fixing the configuration behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp
Domain
cli, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.