You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following application setting is required to run the v4 programming model while it is in preview:
35
+
- Name: `AzureWebJobsFeatureFlags`
36
+
- Value: `EnableWorkerIndexing`
37
+
38
+
If you're running locally using [Azure Functions Core Tools](functions-run-local.md), you should add this setting to your `local.settings.json` file. If you're running in Azure, follow these steps with the tool of your choice:
39
+
40
+
# [Azure CLI](#tab/azure-cli-set-indexing-flag)
41
+
42
+
Replace `<FUNCTION_APP_NAME>` and `<RESOURCE_GROUP_NAME>` with the name of your function app and resource group, respectively.
43
+
44
+
```azurecli
45
+
az functionapp config appsettings set --name <FUNCTION_APP_NAME> --resource-group <RESOURCE_GROUP_NAME> --settings AzureWebJobsFeatureFlags=EnableWorkerIndexing
1. Make sure you have the [Azure Functions extension for VS Code](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions) installed
59
+
1. Press <kbd>F1</kbd> to open the command palette. In the command palette, search for and select `Azure Functions: Add New Setting...`.
60
+
1. Choose your subscription and function app when prompted
61
+
1. For the name, type `AzureWebJobsFeatureFlags` and press <kbd>Enter</kbd>.
62
+
1. For the value, type `EnableWorkerIndexing` and press <kbd>Enter</kbd>.
63
+
64
+
---
65
+
32
66
## Include the npm package
33
67
34
68
For the first time, the [`@azure/functions`](https://www.npmjs.com/package/@azure/functions) npm package contains the primary source code that backs the Node.js programming model. In previous versions, that code shipped directly in Azure and the npm package only had the TypeScript types. Moving forward, you need to include this package for both TypeScript and JavaScript apps. You _can_ include the package for existing v3 apps, but it isn't required.
@@ -327,6 +361,6 @@ The http request and response types are now a subset of the [fetch standard](htt
327
361
328
362
## Troubleshooting
329
363
330
-
If you see the following error, make sure you [set the `EnableWorkerIndexing` flag](./functions-reference-node.md#enable-v4-programming-model) and you're using the minimum version of all [requirements](#requirements):
364
+
If you see the following error, make sure you [set the `EnableWorkerIndexing` flag](#enable-v4-programming-model) and you're using the minimum version of all [requirements](#requirements):
331
365
332
366
> No job functions found. Try making your job classes and methods public. If you're using binding extensions (e.g. Azure Storage, ServiceBus, Timers, etc.) make sure you've called the registration method for the extension(s) in your startup code (e.g. builder.AddAzureStorage(), builder.AddServiceBus(), builder.AddTimers(), etc.).
Copy file name to clipboardExpand all lines: articles/azure-functions/functions-reference-node.md
-34Lines changed: 0 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -68,40 +68,6 @@ At the root of the project, there's a shared [host.json](functions-host-json.md)
68
68
69
69
::: zone pivot="nodejs-model-v4"
70
70
71
-
## Enable v4 programming model
72
-
73
-
The following application setting is required to run the v4 programming model while it is in preview:
74
-
- Name: `AzureWebJobsFeatureFlags`
75
-
- Value: `EnableWorkerIndexing`
76
-
77
-
If you're running locally using [Azure Functions Core Tools](functions-run-local.md), you should add this setting to your `local.settings.json` file. If you're running in Azure, follow these steps with the tool of your choice:
78
-
79
-
# [Azure CLI](#tab/azure-cli-set-indexing-flag)
80
-
81
-
Replace `<FUNCTION_APP_NAME>` and `<RESOURCE_GROUP_NAME>` with the name of your function app and resource group, respectively.
82
-
83
-
```azurecli
84
-
az functionapp config appsettings set --name <FUNCTION_APP_NAME> --resource-group <RESOURCE_GROUP_NAME> --settings AzureWebJobsFeatureFlags=EnableWorkerIndexing
1. Make sure you have the [Azure Functions extension for VS Code](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions) installed
98
-
1. Press <kbd>F1</kbd> to open the command palette. In the command palette, search for and select `Azure Functions: Add New Setting...`.
99
-
1. Choose your subscription and function app when prompted
100
-
1. For the name, type `AzureWebJobsFeatureFlags` and press <kbd>Enter</kbd>.
101
-
1. For the value, type `EnableWorkerIndexing` and press <kbd>Enter</kbd>.
102
-
103
-
---
104
-
105
71
## Folder structure
106
72
107
73
The recommended folder structure for a JavaScript project looks like the following example:
Copy file name to clipboardExpand all lines: includes/functions-nodejs-model-considerations.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ ms.custom: include file
14
14
> [!NOTE]
15
15
> Version 4 of the Node.js programming model is currently in public preview.
16
16
17
-
- During preview, the v4 model requires you to set the app setting `AzureWebJobsFeatureFlags` to `EnableWorkerIndexing`. For more information, see [Enable v4 programming model](../articles/azure-functions/functions-reference-node.md#enable-v4-programming-model).
17
+
- During preview, the v4 model requires you to set the app setting `AzureWebJobsFeatureFlags` to `EnableWorkerIndexing`. For more information, see [Enable v4 programming model](../articles/azure-functions/functions-node-upgrade-v4.md#enable-v4-programming-model).
18
18
- The Node.js "programming model" shouldn't be confused with the Azure Functions "runtime".
19
19
-_**Programming model**_: Defines how you author your code and is specific to JavaScript and TypeScript.
20
20
-_**Runtime**_: Defines underlying behavior of Azure Functions and is shared across all languages.
0 commit comments