Forum Discussion

TomasG's avatar
TomasG
Brass Contributor
Oct 22, 2024
Solved

How to solve issue: Incorrect worker runtime specified for function app (AZFD0013)?

Hi, 

(I apologize if this post is placed incorrectly within the community.)

we've used app Start/Stop VMs during off hours - V2
(GitHub - microsoft/startstopv2-deployments)
(Start/Stop VMs during off hours - V2 - Microsoft Azure)

It worked without any issues, but 8.10 we received the notification described in the article: AZFD0013: The configured runtime does not match the worker runtime metadata found in the deployed function app artifacts. - Azure Functions | Microsoft Learn

In the notification it was written:

We have a new Functions recommendation for startstopvm23dvt65bpvxrmw 

Incorrect worker runtime specified for function app 

We've noticed that your function app (**startstopvm23dvt65bpvxrmw**) is configured with the FUNCTIONS_WORKER_RUNTIME setting as "dotnet-isolated", but expected value for the deployed application payload is "dotnet". This is an unoptimized state which limits performance and may impact application reliability. To help detect this, you may now see the AZFD0013 event raised at the Warning level in your logs. This will be raised to Error level in a future update. To ensure your app can run properly, for its current payload, you should set the FUNCTIONS_WORKER_RUNTIME value to "dotnet". You must also update any deployment automations you have, such as templates or CI/CD pipelines, so they specify the correct value as well. Please see https://aka.ms/functions-invalid-worker-runtime for more information. 

 

If I understand correctly, our FUNCTIONS_WORKER_RUNTIME is set to "dotnet-isolated", and we should reset it to "dotnet"

 

  • When I checked the application settings in Azure, I also get this notification. 
  • When I look in the configuration, there it is set as it is written in GitHub - I assume this setting is correct 

     

  • When I look in the environment variables, and look for FUNCTIONS_WORKER_RUNTIME. So there is dotnet-isolated.

 

But I don't know if by changing this variable, something will not work on dotnet, when the configuration is also set to .NET 8 Isolated?

 

Can anyone advise me on how to proceed to eliminate this problem?

Thanks for all the tips, tricks and advice
Tom

 

 

 

  • Hi Athithya 

    thank you for the response. Finally we received another email -
    Manually update Start/Stop VMs v2 Function App to .NET isolated model to ensure continued functionality

    based on that I did a manual update - which solved the problem.
    It is only necessary to wait about 1 day for the waring message to disappear.

    It can also be verified through the console when listing all files, where if the file StartStopAzureFunctions.dll has a date newer than Aug. 16, 2024, so the warning message should disappear automatically.

    More in the comments:
    https://github.com/microsoft/startstopv2-deployments/issues/143#issuecomment-2463440160

  • TomasG's avatar
    TomasG
    Brass Contributor

    Hi Athithya 

    thank you for the response. Finally we received another email -
    Manually update Start/Stop VMs v2 Function App to .NET isolated model to ensure continued functionality

    based on that I did a manual update - which solved the problem.
    It is only necessary to wait about 1 day for the waring message to disappear.

    It can also be verified through the console when listing all files, where if the file StartStopAzureFunctions.dll has a date newer than Aug. 16, 2024, so the warning message should disappear automatically.

    More in the comments:
    https://github.com/microsoft/startstopv2-deployments/issues/143#issuecomment-2463440160

  • Athithya's avatar
    Athithya
    Brass Contributor

     

    In future In-process model is going to deprecate anyhow. Better you can abide isolated model.

    Yes. configuration setting is correct but please consider the below points

    If you are using .NET framework application and/or .NET SDK like .net framework 4.8 or .net core 3.1, please convert your project to dot-net isolated model. You may need to change some nuget packages.

    For example

    In in-process model,

    your function code starts as 

     [FunctionName("funcname")]

     

    In isolated model, - after migrated from in-process

    your function code will look like below and you need to make some changes in .csproj 

     [Function("funcname")]

     

    Note:  FUNCTIONS_WORKER_RUNTIME value change can affect your func app code running

     

    Please refer

    Migrate .NET function apps from the in-process model to the isolated worker model | Microsoft Learn

     

Resources