I have two web API apps (App Service resources) in Azure: app1 and app2. I'm trying to send https
requests from app1 to app2 but connections fail with this error:
"An error occurred while sending the request. Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host"
When I run app1 on my local dev machine (e.g. from VS 2017
) I can connect to app2 in Azure with no problems.
I use the following code to POST
a request from app1 to app2:
using (HttpClient client = new HttpClient())
{
HttpResponseMessage response = await client.PostAsync(uri, stringContent);
}
uri
? - juunas