@Matthew Evans , Thanks for sharing a detailed description of the issue.
You have stated, the WebApp was recently deployed, just to confirm- have you been experiencing this issue since the time of deployment or after some config change? Do you also receive any specific error message or just the slow response time?
There could be several causes for high response time, to isolate the issue. Kindly try these steps:
- If it’s not done already, turn on
Always On
feature. By default, web apps are unloaded if they are idle for some period of time. This lets the system conserve resources. In Basic or Standard mode, you can enable Always On to keep the app loaded all the time. - On the App Service App, in the left navigation, click on
Diagnose and solve problems
– Checkout the tile for “Diagnostic Tools” > “Availability and Performance” & "Best Practices".
- Update the CPU utilization as 75% for
scale out condition
or 25% for scale-in condition as test and see if that makes any difference (to avoid flapping
condition/I understand you have already analyzed CPU usage) - Isolate/Avoiding the
outbound TCP limits
is easier to solve, as the limits are set by the size of your worker. You can see the limits in Sandbox Cross VM Numerical Limits - TCP Connections- - To avoid outbound TCP limits, you can either increase the size of your workers, or scale out horizontally. - Troubleshooting intermittent outbound connection errors in Azure App Service - (to isolate port exhaustion).
- If there are multiple Apps under a single App Service Plan, distribute the
apps across multiple app service plans
to obtain additional compute levels (to isolate the issue further/shared more details on this in the ‘comment’ section below)
-
Review the logs
to fetch more details on this issue:
You may also inspect the log files from the browser at https://<app-name>.scm.azurewebsites.net/api/logs/docker.