'Use Httpclient.GetStreamAsync() is too slow when ipv6 is not disable in C#

Just like C# code, httpClient.GetAsync() use 10 second or more when ipv6 is not disable. But when I disable ipv6 in win10 System, httpClient.GetAsync() just use 200ms. enter image description here

HttpClient httpClient = new HttpClient(handler);
var response = await httpClient.GetAsync("https://ssl.ptlogin2.qq.com");
Console.WriteLine(response.StatusCode);

I want to know what causes this difference?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source