0

Context: Want to find the total number of connection has been made to Azure Service Plan, under which my application is running. Want to automate it, is there any way ?

So far I have wrote code to connect to the azure with the following code,

function connectionMenthod($AzureUserName,$AzureP,$AzureTenantID,$AzureSubscriptionID) {
    $username = $AzureUserName;
    $password = ConvertTo-SecureString $AzureP -AsPlainText -Force;
    $creds = New-Object System.Management.Automation.PSCredential -ArgumentList ($username, $password);
    Connect-AzAccount -Credential $creds -Tenant $AzureTenantID 
}

function upgradeNFREnvironment () {
    $AzureTenantID = "<Azure_tenant_id>"
    $AzureSubscriptionID = "<Azure_Subscription_Id>"
    $AzureUserName = "<User_Name>"
    $AzureP = "<Password>"
    connectionMenthod $AzureUserName $AzureP $AzureTenantID $AzureSubscriptionID
}

upgradeNFREnvironment 

1 Answers1

0

Want to find the total number of connection has been made to Azure Service Plan, under which my application is running. Want to automate it, is there any way ?

After reading through multiple Azure documentations & blogs understood that currently using PowerShell we don't have any way to pull the total number of established connections of a particular webapp over a period of time.

Using Diagnostics & solve problems blade in the portal , we can check summary about the Total Number of TCP connections established for a particular instance under the webapp over a period of time as show in below

enter image description here

You can refer this documentation for more information about TCP connections in App service & this reference SO thread as well.

VenkateshDodda
  • 4,723
  • 1
  • 3
  • 12