Skip to content

Commit a3d082e

Browse files
Merge pull request #264113 from ecfan/target-scaling
Azure Logic Apps: Add settings for managing target-based scaling
2 parents 562a539 + 87e44de commit a3d082e

File tree

1 file changed

+93
-3
lines changed

1 file changed

+93
-3
lines changed

articles/logic-apps/edit-app-settings-host-settings.md

Lines changed: 93 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ services: logic-apps
55
ms.suite: integration
66
ms.reviewer: estfan, azla
77
ms.topic: how-to
8-
ms.date: 01/18/2024
8+
ms.date: 01/29/2024
99
ms.custom: fasttrack-edit
1010
---
1111

@@ -58,10 +58,11 @@ App settings in Azure Logic Apps work similarly to app settings in Azure Functio
5858
| `FUNCTIONS_WORKER_RUNTIME` | `node` | Sets the language worker runtime to use with your logic app resource and workflows. However, this setting is no longer necessary due to automatically enabled multi-language support. <br><br>For more information, see [FUNCTIONS_WORKER_RUNTIME](../azure-functions/functions-app-settings.md#functions_worker_runtime). |
5959
| `ServiceProviders.Sftp.FileUploadBufferTimeForTrigger` | `00:00:20` <br>(20 seconds) | Sets the buffer time to ignore files that have a last modified timestamp that's greater than the current time. This setting is useful when large file writes take a long time and avoids fetching data for a partially written file. |
6060
| `ServiceProviders.Sftp.OperationTimeout` | `00:02:00` <br>(2 min) | Sets the time to wait before timing out on any operation. |
61-
| `ServiceProviders.Sftp.ServerAliveInterval` | `00:30:00` <br>(30 min) | Send a "keep alive" message to keep the SSH connection active if no data exchange with the server happens during the specified period. |
61+
| `ServiceProviders.Sftp.ServerAliveInterval` | `00:30:00` <br>(30 min) | Sends a "keep alive" message to keep the SSH connection active if no data exchange with the server happens during the specified period. |
6262
| `ServiceProviders.Sftp.SftpConnectionPoolSize` | `2` connections | Sets the number of connections that each processor can cache. The total number of connections that you can cache is *ProcessorCount* multiplied by the setting value. |
6363
| `ServiceProviders.MaximumAllowedTriggerStateSizeInKB` | `10` KB, which is ~1,000 files | Sets the trigger state entity size in kilobytes, which is proportional to the number of files in the monitored folder and is used to detect files. If the number of files exceeds 1,000, increase this value. |
6464
| `ServiceProviders.Sql.QueryTimeout` | `00:02:00` <br>(2 min) | Sets the request timeout value for SQL service provider operations. |
65+
| `TARGET_BASED_SCALING_ENABLED` | `1` | Sets Azure Logic Apps to use target-based scaling (`1`) or incremental scaling (`0`). By default, target-based scaling is automatically enabled. For more information see [Target-based scaling](#scaling). |
6566
| `WEBSITE_LOAD_ROOT_CERTIFICATES` | None | Sets the thumbprints for the root certificates to be trusted. |
6667
| `Workflows.Connection.AuthenticationAudience` | None | Sets the audience for authenticating a managed (Azure-hosted) connection. |
6768
| `Workflows.CustomHostName` | None | Sets the host name to use for workflow and input-output URLs, for example, "logic.contoso.com". For information to configure a custom DNS name, see [Map an existing custom DNS name to Azure App Service](../app-service/app-service-web-tutorial-custom-domain.md) and [Secure a custom DNS name with a TLS/SSL binding in Azure App Service](../app-service/configure-ssl-bindings.md). |
@@ -142,7 +143,6 @@ To add or update an app setting using the Azure CLI, run the command `az logicap
142143
```azurecli
143144
az logicapp config appsettings set --name MyLogicApp --resource-group MyResourceGroup --settings CUSTOM_LOGIC_APP_SETTING=12345
144145
```
145-
146146
---
147147

148148
<a name="reference-host-json"></a>
@@ -184,6 +184,96 @@ The following example shows the syntax for these settings where each workflow ID
184184
"Jobs.SuspendedJobPartitionPrefixes": "<workflow-ID-1>:; <workflow-ID-2>:"
185185
```
186186

187+
<a name="scaling"></a>
188+
189+
### Target-based scaling
190+
191+
Single-tenant Azure Logic Apps gives you the option to select your preferred compute resources and set up your logic app resources to dynamically scale based on varying workload demands. The target-based scaling model used by Azure Logic Apps includes settings that you can use to fine-tune the model's underlying dynamic scaling mechanism, which can result in faster scale-out and scale-in times. For more information about the target-based scaling model, see the following articles:
192+
193+
- [Target-based scaling support in single-tenant Azure Logic Apps](https://techcommunity.microsoft.com/t5/azure-integration-services-blog/announcement-target-based-scaling-support-in-azure-logic-apps/ba-p/3998712)
194+
- [Single-tenant Azure Logic Apps target-based scaling performance benchmark - Burst workloads](https://techcommunity.microsoft.com/t5/azure-integration-services-blog/logic-apps-standard-target-based-scaling-performance-benchmark/ba-p/3998807)
195+
196+
#### Considerations
197+
198+
- Target-based scaling isn't available or supported for Standard workflows running on an App Service Environment or Consumption plan.
199+
200+
- If you have scale-in requests without any scale-out requests, Azure Logic Apps uses the maximum scale-in value. Target-based scaling can scale down unused worker instances faster, resulting in more efficient resource usage.
201+
202+
#### Requirements
203+
204+
- Your logic apps must use [Azure Functions runtime version 4.3.0 or later](../azure-functions/set-runtime-version.md).
205+
206+
- Your logic app workflows must use single-tenant Azure Logic Apps runtime version 1.55.1 or later.
207+
208+
#### Target-based scaling settings in host.json
209+
210+
| Setting | Default value | Description |
211+
|---------|---------------|-------------|
212+
| `Runtime.TargetScaler.TargetConcurrency` | `null` | The number of target executions per worker instance. By default, the value is `null`. If you leave this value unchanged, your logic app defaults to using dynamic concurrency. You can set a targeted maximum value for concurrent job polling by using this setting. For an example, see the section following this table. |
213+
| `Runtime.TargetScaler.TargetScalingCPU` | `70` | The maximum percentage of CPU usage that you expect at target concurrency. You can change this default percentage for each logic app by using this setting. For an example, see the section following this table. |
214+
| `Runtime.TargetScaler.TargetScalingFactor` | `0.3` | A numerical value from `0.05` to `1.0` that determines the degree of scaling intensity. A higher target scaling factor results in more aggressive scaling. A lower target scaling factor results in more conservative scaling. You can fine-tune the target scaling factor for each logic app by using this setting. For an example, see the section following this table. |
215+
216+
##### TargetConcurrency example
217+
218+
```json
219+
{
220+
"version": "2.0",
221+
"extensionBundle": {
222+
"id": "Microsoft.Azure.Functions.ExtensionBundle.Workflows",
223+
"version": "[1.*, 2.0.0)"
224+
},
225+
"extensions": {
226+
"workflow": {
227+
"Settings": {
228+
"Runtime.TargetScaler.TargetConcurrency": "280"
229+
}
230+
}
231+
}
232+
}
233+
```
234+
235+
#### TargetScalingCPU example
236+
237+
```json
238+
{
239+
"version": "2.0",
240+
"extensionBundle": {
241+
"id": "Microsoft.Azure.Functions.ExtensionBundle.Workflows",
242+
"version": "[1.*, 2.0.0)"
243+
},
244+
"extensions": {
245+
"workflow": {
246+
"Settings": {
247+
"Runtime.TargetScaler.TargetScalingCPU": "76"
248+
}
249+
}
250+
}
251+
}
252+
```
253+
254+
##### TargetScalingFactor example
255+
256+
```json
257+
{
258+
"version": "2.0",
259+
"extensionBundle": {
260+
"id": "Microsoft.Azure.Functions.ExtensionBundle.Workflows",
261+
"version": "[1.*, 2.0.0)"
262+
},
263+
"extensions": {
264+
"workflow": {
265+
"Settings": {
266+
"Runtime.TargetScaler.TargetScalingFactor": "0.62"
267+
}
268+
}
269+
}
270+
}
271+
```
272+
273+
#### Disable target-based scaling
274+
275+
By default, target-based scaling is automatically enabled. To opt out from using target-based scaling and revert back to incremental scaling, add the app setting named **TARGET_BASED_SCALING_ENABLED** and set the value set to **0** in your Standard logic app resource using the Azure portal or in your logic app project's **local.settings.json file** using Visual Studio Code. For more information, see [Manage app settings - local.settings.json](#manage-app-settings).
276+
187277
<a name="recurrence-triggers"></a>
188278

189279
### Recurrence-based triggers

0 commit comments

Comments
 (0)