LogicAppsUX
LogicAppsUX copied to clipboard
Duplicate HTTP POST executions in Logic Apps despite retryPolicy = none
Severity
P1 - Critical (Blocking production)
Describe the Bug with repro steps
Expected behavior:
- The Logic App action HTTP_-_POST_PH_Time should execute exactly once per workflow run, sending a single HTTP POST request to the configured external API (PHTimeURL).
- No duplicate requests should be made when retryPolicy is set to none.
- The Logic App run history in the portal should accurately reflect all network requests made.
Actual behavior:
-
During a single Logic App run, the external API received two identical POST requests with the same request body.
-
The API (PHTimeURL) telemetry shows:
- First request started at 2025-09-15T21:01:12Z, duration ~190s.
- Second request started at 2025-09-15T21:05:44Z, duration ~120s.
-
In the Logic App portal run history:
- Only one run exists for this trigger.
- The HTTP_-_POST_PH_Time action appears only once (start 09:05:44 NZST, end 09:07:44 NZST).
- No retries are displayed, and the action is configured with "retryPolicy": { "type": "none" }.
-
Despite this, the external system confirms two POSTs occurred.
Steps to reproduce:
- Create a Logic App with the following structure:
- Trigger: When a HTTP request is received.
- Initialize array variable.
- Process payload via For_each, build up an array (TimesheetOutput).
- Final action: HTTP POST (HTTP_-_POST_PH_Time) sending the array to an external API.
- Configure HTTP action with:
"retryPolicy": {
"type": "none"
},
"runtimeConfiguration": {
"contentTransfer": {
"transferMode": "Chunked"
}
}
-
Set runAfter so the HTTP POST executes after the foreach completes (Succeeded, TimedOut, Skipped, Failed).
-
Trigger the Logic App with a payload large enough to require chunked transfer.
-
Observe:
- Only one Logic App run appears in the portal.
- The HTTP POST action appears once in the run history (with start ~4 minutes after the foreach ends).
- The target API, however, logs two POST requests with identical bodies: one at the time the foreach completed, and another at the time the portal shows the HTTP action ran.
What type of Logic App Is this happening in?
Consumption (Portal)
Are you experiencing a regression?
Been running since last 6 months, runs twice (mostly Mondays and Tuesdays) every 15 days, last successful run was: 9/15/2025 9:00 AM
Which operating system are you using?
Windows
Did you refer to the TSG before filing this issue? https://aka.ms/lauxtsg
Yes
Workflow JSON
{
"definition": {
"$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",
"contentVersion": "1.0.0.0",
"triggers": {
"When_a_HTTP_request_is_received": {
"type": "Request",
"kind": "Http"
}
},
"actions": {
"Initialize_variable_-_TimesheetOutput": {
"type": "InitializeVariable",
"inputs": {
"variables": [
{
"name": "TimesheetOutput",
"type": "array"
}
]
},
"runAfter": {}
},
"Scope_-_Processing": {
"type": "Scope",
"actions": {
"HTTP_-_POST_PH_Login": {
"type": "Http",
"inputs": {
"uri": "@{parameters('PHLoginURL')}",
"method": "POST",
"headers": {
"Api-Subscription-Key": "@{parameters('PHAPISubKey')}",
"Content-Type": "application/json"
},
"body": {
"api_key": "@{parameters('PHAPIKey')}"
}
},
"runtimeConfiguration": {
"contentTransfer": {
"transferMode": "Chunked"
}
}
},
"For_each_-_HF_Timesheet": {
"type": "Foreach",
"foreach": "@triggerBody()",
"actions": {
"For_each_-_PayTypes": {
"type": "Foreach",
"foreach": "@items('For_each_-_HF_Timesheet')['PayTypes']",
"actions": {
"Compose_-_PayType": {
"type": "Compose",
"inputs": {
"work_key": "@body('Get_entity_-_WorkKey')?['work_key']",
"units": "@items('For_each_-_PayTypes')?['Value']",
"employee_key": "@outputs('Compose_-_EmpTimesheet')?['employee_key']",
"time_date": "@outputs('Compose_-_EmpTimesheet')?['time_date']",
"deleted_flag": "@outputs('Compose_-_EmpTimesheet')?['deleted_flag']",
"description": "@outputs('Compose_-_EmpTimesheet')?['description']"
},
"runAfter": {
"Get_entity_-_WorkKey": [
"Succeeded"
]
}
},
"Append_to_array_variable_-_TimesheetOutput": {
"type": "AppendToArrayVariable",
"inputs": {
"name": "TimesheetOutput",
"value": "@outputs('Compose_-_PayType')"
},
"runAfter": {
"Compose_-_PayType": [
"Succeeded"
]
}
},
"Get_entity_-_WorkKey": {
"type": "ApiConnection",
"inputs": {
"host": {
"connection": {
"name": "@parameters('$connections')['azuretables']['connectionId']"
}
},
"method": "get",
"path": "/v2/storageAccounts/@{encodeURIComponent(encodeURIComponent('AccountNameFromSettings'))}/tables/@{encodeURIComponent('WorkKey')}/entities(PartitionKey='@{encodeURIComponent('work_key')}',RowKey='@{encodeURIComponent(items('For_each_-_PayTypes')?['PayType']?['ExportCode'])}')"
}
}
},
"runAfter": {
"Compose_-_EmpTimesheet": [
"Succeeded"
]
},
"runtimeConfiguration": {
"concurrency": {
"repetitions": 1
}
}
},
"Compose_-_EmpTimesheet": {
"type": "Compose",
"inputs": {
"employee_key": "@items('For_each_-_HF_Timesheet')?['Employee']?['EmployeeCode']",
"time_date": "@formatDateTime(if(equals(items('For_each_-_HF_Timesheet')?['Role']?['Name'], 'Lab Night'), items('For_each_-_HF_Timesheet')?['DateStart'], items('For_each_-_HF_Timesheet')?['PayEndTime']), 'yyyy-MM-dd')",
"deleted_flag": "@items('For_each_-_HF_Timesheet')?['Deleted']",
"description": "@items('For_each_-_HF_Timesheet')?['Comments']"
}
}
},
"runAfter": {
"HTTP_-_POST_PH_Login": [
"Succeeded"
]
},
"runtimeConfiguration": {
"concurrency": {
"repetitions": 50
}
}
},
"HTTP_-_POST_PH_Time": {
"type": "Http",
"inputs": {
"uri": "@{parameters('PHTimeURL')}",
"method": "POST",
"headers": {
"Content-Type": "application/json",
"Cache-Control": "no-cache",
"Authorization": "@{body('HTTP_-_POST_PH_Login')?['company_auth']}",
"Api-Subscription-Key": "@{parameters('PHAPISubKey')}"
},
"body": {
"times": "@variables('TimesheetOutput')"
},
"retryPolicy": {
"type": "none"
}
},
"runAfter": {
"For_each_-_HF_Timesheet": [
"Succeeded",
"TimedOut",
"Skipped",
"Failed"
]
},
"runtimeConfiguration": {
"contentTransfer": {
"transferMode": "Chunked"
}
}
}
},
"runAfter": {
"Initialize_variable_-_TimesheetOutput": [
"Succeeded"
]
}
}
},
"outputs": {},
"parameters": {
"PHAPISubKey": {
"defaultValue": "f219bbded413481f90b3350d56c4d7d1",
"type": "String"
},
"PHAPIKey": {
"defaultValue": "FAB38C31-92A8-420E-AFDE-56A6BA39447D",
"type": "String"
},
"PHLoginURL": {
"defaultValue": "https://payhero-public.azure-api.net/login",
"type": "String"
},
"PHTimeURL": {
"defaultValue": "https://payhero-public.azure-api.net/time",
"type": "String"
},
"$connections": {
"type": "Object",
"defaultValue": {}
}
}
},
"parameters": {
"$connections": {
"type": "Object",
"value": {
"azuretables": {
"id": "/subscriptions/02189055-c2ed-4d14-b45d-a419c9011967/providers/Microsoft.Web/locations/australiaeast/managedApis/azuretables",
"connectionId": "/subscriptions/02189055-c2ed-4d14-b45d-a419c9011967/resourceGroups/NZCR-ADAPTIVE/providers/Microsoft.Web/connections/azuretables-1",
"connectionName": "azuretables-1"
}
}
}
}
}
Screenshots or Videos
No response
Environment
- Browser: Chrome 140 (used for portal access to Logic Apps run history)
- VS Code Version: N/A (issue observed in runtime, not in local development)
- Extension Version: N/A (not using the Logic Apps VS Code extension)
- Azure CLI Version: N/A (not using CLI to reproduce; issue occurs in Logic Apps runtime execution in Azure Portal)
- Azure Environment: Logic App Consumption, Region = Australia East
Additional context
No response