-
Notifications
You must be signed in to change notification settings - Fork 0
Azure Function Runtime Version
There are two major versions: 1.x for .Net Framework and 2.x for .Net Standard.
- Major version :
~1for 1.x ,betaor~2for 2.x. With this format, function app on Azure is automatically updated to new minor versions of the runtime when they become available. - Minor version 1.x:
1.0.11959; 2.x:2.0.11961-alpha,2.0.12050-alpha. (All versions available right now). Function app on Azure is kept on that version until we explicitly change it.
- Runtime version in Function app settings.
-
FUNCTIONS_EXTENSION_VERSIONin Application settings.
Two scenarios we need to change runtime.
-
Major version change. ~1 to beta/~2 or reverse.
We may see prompt below if there are functions in the app.
Major version upgrades can introduce breaking changes to languages and bindings. When upgrading major versions of the runtime, consider creating a new function app and migrate your functions to this new app.
-
In an empty function app(delete existing functions or create new app), change runtime in Function app settings.
-
We can directly set
FUNCTIONS_EXTENSION_VERSIONin Application settings if published project depends on another runtime.
-
-
Minor version pinned to avoid breaking changes(probably the last time to use as 2.x is planned to be GA by this fall).
See breaking changes in 2.0.12050-alpha(beta), we can pin FUNCTIONS_EXTENSION_VERSION to 2.0.11961-alpha and follow steps to work with changes and move to beta.
Find more breaking changes to fix if our 2.x function runtime is pinned to some older version, which have all been removed on Azure.
If we specify a wrong version of 1.x like 1.0.14, Azure will leverage latest minor version instead. It is same with 2.x.
Commonly speaking, local dev doesn't need runtime configuration because we choose Cli first(using tools like npm or VS does in background), we are clear about the major version at least.
Some local places to find function runtime version.
- VS, New Function project v1 or v2.
- VS/VSCode c# function, in functionappname.csproj, see
<AzureFunctionsVersion>v2</AzureFunctionsVersion>. - VSCode, functionapp/.vscode/setting.json, see
"azureFunctions.projectRuntime": "beta" - Function core tools(Cli), run
func, we may seeFunction Runtime Version:2.0.12050.0 - Start a function app in VS/VSCode/Cli, besides 4, we can also see Cli output
Starting Host (HostId=xx, InstanceId=xx, Version=2.0.12050.0, ..)
This is my footer