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
Copy file name to clipboardExpand all lines: articles/logic-apps/create-single-tenant-workflows-visual-studio-code.md
+74-21Lines changed: 74 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ services: logic-apps
5
5
ms.suite: integration
6
6
ms.reviewer: estfan, azla
7
7
ms.topic: how-to
8
-
ms.date: 01/15/2025
8
+
ms.date: 02/10/2025
9
9
ms.custom: engagement-fy23, devx-track-dotnet
10
10
# Customer intent: As a logic apps developer, I want to create a Standard logic app workflow that runs in single-tenant Azure Logic Apps using Visual Studio Code.
11
11
---
@@ -24,10 +24,6 @@ This how-to guide shows how to create an example integration workflow that runs
24
24
25
25
When you're ready, you can deploy your logic app to Azure where your workflow can run in the single-tenant Azure Logic Apps environment or in an App Service Environment v3 (Windows-based App Service plans only). You can also deploy and run your workflow anywhere that Kubernetes can run, including Azure, Azure Kubernetes Service, on premises, or even other cloud providers, due to the Azure Logic Apps containerized runtime.
26
26
27
-
> [!NOTE]
28
-
>
29
-
> Deploying your logic app to a Kubernetes cluster is currently in public preview.
30
-
31
27
For more information about single-tenant Azure Logic Apps, see [Single-tenant versus multitenant in Azure Logic Apps](single-tenant-overview-compare.md#resource-environment-differences).
32
28
33
29
While the example workflow is cloud-based and has only two steps, you can create workflows from hundreds of operations that can connect a wide range of apps, data, services, and systems across cloud, on premises, and hybrid environments. The example workflow starts with the built-in **Request** trigger and follows with an Office 365 Outlook action. The trigger creates a callable endpoint for the workflow and waits for an inbound HTTPS request from any caller. When the trigger receives a request and fires, the next action runs by sending email to the specified email address along with selected outputs from the trigger.
@@ -221,9 +217,9 @@ As you progress, you'll complete these high-level tasks:
221
217
222
218
Currently, you can have both Consumption (multitenant) and Standard (single-tenant) extensions installed at the same time. The development experiences differ from each other in some ways, but your Azure subscription can include both Standard and Consumption logic app types. In Visual Studio Code, the Azure window shows all the Azure-deployed and hosted logic apps in your Azure subscription, but organizes your apps in the following ways:
223
219
224
-
***Logic Apps (Consumption)** section: All the Consumption logic apps in your subscription.
220
+
***Resources** section: All the Standard logic apps in your subscription.
225
221
226
-
***Resources** section: All the Standard logic apps in your subscription. Previously, these logic apps appeared in the **Logic Apps (Standard)** section, which has now moved into the **Resources** section.
222
+
***Logic Apps (Consumption)** section: All the Consumption logic apps in your subscription.
227
223
228
224
1. To locally run webhook-based triggers and actions, such as the [built-in HTTP Webhook trigger](../connectors/connectors-native-webhook.md), in Visual Studio Code, you need to [set up forwarding for the callback URL](#webhook-setup).
229
225
@@ -250,6 +246,7 @@ As you progress, you'll complete these high-level tasks:
250
246
1. Confirm that the **Azure Logic Apps Standard: Project Runtime** setting for the Azure Logic Apps (Standard) extension is set to version **~4**:
251
247
252
248
> [!NOTE]
249
+
>
253
250
> This version is required to use the [Inline Code Operations actions](../logic-apps/logic-apps-add-run-inline-code.md).
254
251
255
252
1. On the **File** menu, go to **Preferences****>****Settings**.
@@ -282,31 +279,53 @@ As you progress, you'll complete these high-level tasks:
282
279
283
280
1. When another subscriptions list appears, select the subscriptions that you want, and make sure that you select **OK**.
284
281
285
-
<aname="create-project"></a>
282
+
<aname="create-workspace"></a>
283
+
284
+
## Create a local workspace
286
285
287
-
## Create a local project
286
+
Before you can create your logic app, create your logic app [workspace](https://code.visualstudio.com/docs/editor/workspaces/workspaces) where you keep your logic app project. A logic app project always requires a workspace. You later use this workspace and project to manage, run, and deploy your logic app from Visual Studio Code to your deployment environment. The underlying project is similar to an Azure Functions project, also known as a function app project.
288
287
289
-
Before you can create your logic app, create a local project so that you can manage, run, and deploy your logic app from Visual Studio Code. The underlying project is similar to an Azure Functions project, also known as a function app project. However, these project types are separate from each other, so logic apps and function apps can't exist in the same project.
288
+
1. On your computer, create an *empty*local folder to use later for the workspace and project.
290
289
291
-
1. On your computer, create an *empty* local folder to use for the project that you'll later create in Visual Studio Code.
290
+
This example creates a folder named **fabrikam-workflows**.
292
291
293
292
1. In Visual Studio Code, close all open folders.
294
293
295
-
1. In the **Azure** window, on the **Workspace** section toolbar, from the **Azure Logic Apps** menu, select **Create new project**.
294
+
1. In the **Azure** window, on the **Workspace** section toolbar, from the **Azure Logic Apps** menu, select **Create new logic app workspace**.
296
295
297
-

296
+

298
297
299
298
1. If Windows Defender Firewall prompts you to grant network access for **Code.exe**, which is Visual Studio Code, and for **func.exe**, which is the Azure Functions Core Tools, select **Private networks, such as my home or work network****>****Allow access**.
300
299
301
-
1. Browse to the location where you created your project folder, select that folder and continue.
300
+
1. Browse to the location where you created your workspace and project folder, select that folder, and continue.
301
+
302
+

303
+
304
+
1. In the Visual Studio Code toolbar area, in the workspace prompt that appears, enter a name for your workspace.
305
+
306
+
This example uses **Fabrikam-Workflows**.
307
+
308
+
Now, follow the prompts to create your logic app project.
309
+
310
+
<aname="create-project"></a>
311
+
312
+
## Create your logic app project
313
+
314
+
After you create the required workspace, follow the prompts that appear to create your project.
302
315
303
-

316
+
1. When the project template prompt appears, select **Logic app**, and enter a name for your logic app project.
304
317
305
-
1. From the templates list that appears, select either **Stateful Workflow** or **Stateless Workflow**. This example selects **Stateful Workflow**.
318
+
This example uses **Fabrikam-Workflows**.
319
+
320
+
1. When the workflow template list that appears, select either **Stateful Workflow** or **Stateless Workflow**.
321
+
322
+
This example selects **Stateful Workflow**.
306
323
307
324

308
325
309
-
1. Provide a name for your workflow and press Enter. This example uses **Stateful-Workflow** as the name.
326
+
1. Enter a name for your workflow.
327
+
328
+
This example uses **Stateful-Workflow**.
310
329
311
330

312
331
@@ -319,18 +338,51 @@ Before you can create your logic app, create a local project so that you can man
319
338
320
339
1. If Visual Studio Code prompts you to open your project in the current Visual Studio Code or in a new Visual Studio Code window, select **Open in current window**. Otherwise, select **Open in new window**.
321
340
322
-
Visual Studio Code finishes creating your project.
341
+
1. When the **Enable connectors in Azure** prompt appears, select **Use connectors from Azure**.
342
+
343
+
This option lets you browse all the "shared" connector operations that are hosted and run in multitenant Azure. Otherwise, you can only browse the "in-app" operations, which are the built-in, native operations that directly run with the Azure Logic Apps runtime.
344
+
345
+
1. When the **Select subscription** prompt appears, select the Azure subscription to use with your logic app project, for example:
346
+
347
+

348
+
349
+
1. When the **Select a resource group for new resources** prompt appears, select **Create new resource group**.
350
+
351
+

352
+
353
+
1. Enter the name to use for the Azure resource group.
354
+
355
+
This example uses **Fabrikam-Workflows-RG**.
356
+
357
+

358
+
359
+
1. When the **Select a location for new resources** prompt appears, select the Azure region to use for creating your resource group and resources.
360
+
361
+
This example uses **West Central US**.
362
+
363
+

364
+
365
+
Your project is now ready for you to start building your workflow.
366
+
367
+
368
+
After you perform this step, Visual Studio Code opens the workflow designer.
369
+
370
+
> [!NOTE]
371
+
> When Visual Studio Code starts the workflow design-time API, you might get a message
372
+
> that startup might take a few seconds. You can ignore this message or select **OK**.
373
+
>
374
+
> If the designer won't open, see the troubleshooting section, [Designer fails to open](#designer-fails-to-open).
323
375
324
376
1. From the Visual Studio Activity Bar, open the Explorer pane, if not already open.
325
377
326
-
The Explorer pane shows your project, which now includes automatically generated project files. For example, the project has a folder that shows your workflow's name. Inside this folder, the **workflow.json** file contains your workflow's underlying JSON definition.
378
+
The Explorer pane shows your workspace and project, which now includes automatically generated project files. For example, the project has a folder that shows your workflow's name. Inside this folder, the **workflow.json** file contains your workflow's underlying JSON definition.
327
379
328
-

380
+

329
381
330
382
[!INCLUDE [Visual Studio Code - logic app project structure](includes/logic-apps-single-tenant-project-structure-visual-studio-code.md)]
331
383
332
384
> [!NOTE]
333
-
>
385
+
>
334
386
> The **FUNCTIONS_WORKER_RUNTIME** app setting is required for your Standard logic app, and the
335
387
> value was previously set to **node**. However, the required value is now **dotnet** for all new
336
388
> and existing deployed Standard logic apps. This change in value shouldn't affect your workflow's
@@ -413,6 +465,7 @@ For more information about uploading assemblies to your logic app resource in th
413
465
### Migrate NuGet-based projects to use "lib\\*" assemblies
414
466
415
467
> [!IMPORTANT]
468
+
>
416
469
> This task is required only for NuGet-based logic app projects.
417
470
418
471
If you created your logic app project when assemblies support wasn't available for Standard logic app workflows, you can add the following lines to your **<*project-name*>.csproj** file to work with projects that use assemblies:
Copy file name to clipboardExpand all lines: articles/logic-apps/includes/logic-apps-single-tenant-project-structure-visual-studio-code.md
+30-20Lines changed: 30 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,37 +16,47 @@ Based on these types, your project includes slightly different folders and files
16
16
For the default bundle-based project, your project has a folder and file structure that is similar to the following example:
17
17
18
18
```text
19
-
MyBundleBasedLogicAppProjectName
20
-
| .vscode
21
-
| Artifacts
22
-
|| Maps
23
-
||| MapName1
19
+
MyWorkspaceName
20
+
| MyBundleBasedLogicAppProjectName
21
+
|| .vscode
22
+
|| Artifacts
23
+
||| Maps
24
+
|||| MapName1
25
+
|||| ...
26
+
||| Rules
27
+
||| Schemas
28
+
|||| SchemaName1
29
+
|||| ...
30
+
|| lib
31
+
||| builtinOperationSdks
32
+
|||| JAR
33
+
|||| net472
34
+
||| custom
35
+
|| WorkflowName1
36
+
||| workflow.json
24
37
||| ...
25
-
|| Schemas
26
-
||| SchemaName1
38
+
|| WorkflowName2
39
+
||| workflow.json
27
40
||| ...
28
-
| WorkflowName1
29
-
|| workflow.json
30
-
|| ...
31
-
| WorkflowName2
32
-
|| workflow.json
33
-
|| ...
34
-
| workflow-designtime
35
-
| .funcignore
36
-
| connections.json
37
-
| host.json
38
-
| local.settings.json
41
+
|| workflow-designtime
42
+
||| host.json
43
+
||| local.settings.json
44
+
|| .funcignore
45
+
|| connections.json
46
+
|| host.json
47
+
|| local.settings.json
39
48
```
40
49
41
50
At your project's root level, you can find the following files and folders with other items:
42
51
43
52
| Name | Folder or file | Description |
44
53
|------|----------------|-------------|
45
54
|**.vscode**| Folder | Contains Visual Studio Code-related settings files, such as **extensions.json**, **launch.json**, **settings.json**, and **tasks.json** files. |
46
-
|**Artifacts**| Folder | Contains integration account artifacts that you define and use in workflows that support business-to-business (B2B) scenarios. For example, the example structure includes maps and schemas for XML transform and validation operations. |
55
+
|**Artifacts**| Folder | Contains integration account artifacts that you define and use in workflows that support business-to-business (B2B) scenarios. For example, the sample structure includes the following folders: <br><br>- **Maps**: Contains [maps](/azure/logic-apps/logic-apps-enterprise-integration-maps) to use for XML transformation operations. <br><br>- **Schemas**: Contains [schemas](/azure/logic-apps/logic-apps-enterprise-integration-schemas) to use for XML validation operations. <br><br>- **Rules**: Artifacts for [business rules in rules-based engine projects](/azure/logic-apps/rules-engine/rules-engine-overview.md). |
56
+
|**lib**| Folder | Contains supported assemblies that your logic app can use or reference. You can upload these assemblies to your project in Visual Studio Code, but you must add them to specific folders in your project. <br><br>For more information about supported assembly types and where to put them in your project, see [Add assemblies to your project](/azure/logic-apps/create-single-tenant-workflows-visual-studio-code#add-assembly). |
47
57
|**<*WorkflowName*>**| Folder | For each workflow, the <*WorkflowName*> folder includes a **workflow.json** file, which contains that workflow's underlying JSON definition. |
48
58
|**workflow-designtime**| Folder | Contains development environment-related settings files. |
49
-
|**.funcignore**| File | Contains information related to your installed [Azure Functions Core Tools](../../azure-functions/functions-run-local.md). |
59
+
|**.funcignore**| File | Contains information related to your installed [Azure Functions Core Tools](/azure/azure-functions/functions-run-local). |
50
60
|**connections.json**| File | Contains the metadata, endpoints, and keys for any managed connections and Azure functions that your workflows use. <br><br>**Important**: To use different connections and functions for each environment, make sure that you parameterize this **connections.json** file and update the endpoints. |
51
61
| **host.json** | File | Contains runtime-specific configuration settings and values, for example, the default limits for the single-tenant Azure Logic Apps platform, logic apps, workflows, triggers, and actions. At your logic app project's root level, the **host.json** metadata file contains the configuration settings and default values that *all workflows* in the same logic app use while running, whether locally or in Azure. <br><br>**Note**: When you create your logic app, Visual Studio Code creates a backup **host.snapshot.*.json** file in your storage container. If you delete your logic app, this backup file isn't deleted. If you create another logic app with the same name, another snapshot file is created. You can have only up to 10 snapshots for the same logic app. If you exceed this limit, you get the following error: <br><br>`Microsoft.Azure.WebJobs.Script.WebHost: Repository has more than 10 non-decryptable secrets backups (host))` <br><br>To resolve this error, delete the extra snapshot files from your storage container. |
52
62
|**local.settings.json**| File | Contains app settings, connection strings, and other settings that your workflows use while running locally. In other words, these settings and values apply *only* when you run your projects in your local development environment. During deployment to Azure, the file and settings are ignored and aren't included with your deployment. <br><br>This file stores settings and values as *local environment variables* that are used by your local development tools as the `appSettings` values. You can call and reference these environment variables both at runtime and deployment time by using *app settings* and *parameters*. <br><br>**Important**: The **local.settings.json** file can contain secrets, so make sure that you also exclude this file from your project source control. |
0 commit comments