I am facing a strange problem. I have a mvc web application developed and running on my local machine and can connect to an API https://api-uat1.%domain%.com:443 from the [api_root] configured as an app setting in the web config. But this is on my local.
Now i publish this app on Azure with the same connection string in the Application settings option in the blade and also the web config.
But this says the remote host not found when i run the application from Azure.
The error i am getting is
System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The remote name could not be resolved: 'api.uat1.<domain>.com'
at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)
--- End of inner exception stack trace ---<---
Is there a way i can debug the API via SOAP UI or fiddler but not sure where to look at the exact cause. Can anyone help ?
You can debug your Azure app following the instructions outlined https://learn.microsoft.com/en-us/visualstudio/debugger/remote-debugging-azure?view=vs-2017#remote_debug_azure_app_service. Just make sure you've published your app in Debug mode so that symbols will be published along with the application binaries.