We use a source generator project with our azure functions project to generate our event grid triggered functions and recently migrated the project to .NET 8.
After migrating to .NET 8, we noticed that the generated functions weren't showing up anymore after deploying the functions app to Azure.
Using dotPeek we checked the output .dll files to check that the source generated function classes were present, and found that they were, but there were also 2 new generated classes:
DirectFunctionExecutorGeneratedFunctionMetadataProvider
The new classes have methods that return meta info about the functions in the dll, and a mechanism to execute them without having to use reflection.
Unfortunately the function classes generated by our source generator project were not in the function classes listed in these 2 new sdk generated classes, and therefore were not registered as functions after deploying the functions app.
We expected the source generated functions to be registered and available in the functions host after deploying.
We were given guidance from MS that by adding these two settings to the functions projects .csproj file, the new sdk generated classes are not included in the output .dll and the functions host reverts back to using reflection to determine what functions should be registered.