Kreya
Kreya copied to clipboard
Somehow, there is an exact 2s delay from nameserver resolution to connection setup
Describe the bug I've been experimenting with a local grpc server when I saw that each call needs exactly around 2 seconds. Between "resolution stop" and "connection established" there is a 2s delay for no reason. When I tried the same call in Insomnia gRPC, it was nearly instant.
To Reproduce Steps to reproduce the behavior:
- Have a grpc server
- Create a call
- Send call :)
Expected behavior That it should be blazingly fast
Screenshots
Environment (if possible, copy the information from the error dialog or the About menu):
- OS: Win 11
- Kreya Version: 1.7.0 Stable
{ "kreyaVersion": "1.7.0", "platform": "Win32", "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.51 Safari/537.36 Edg/99.0.1150.30" }
I cannot reproduce this:
Could you try calling your API via http://127.0.0.1:8080
and http://[::1]:8080
? I suspect IPv6 issues when resolving localhost
, where Kreya tries to connect to the "IPv6 IP", but has to fall back to the "IPv4 IP".
Huhu :)
Yep, when I use 127.0.0.1
it is blazingly fast.
Ok, then that's the workaround for now...
As for improving this, we are blocked until https://github.com/dotnet/runtime/issues/26177 has been implemented into the .NET "gRPC infrastructure" (mainly HttpClient/SocketsHttpHandler).